title: Create Docker container with Django, npm and gulp
body: <p>I changed my local dev. to Docker. I use the Django framework. For frontend I use the gulp build command to “create” my files. Now I tried a lot, looked into the Cookiecutter and Saleor project but still having issues to install npm in a way that I can call the gulp build command in my Docker container.</p>
  
  <p>I already tried to add:</p>
  
  <pre><code>RUN curl -sL https://deb.nodesource.com/setup_10.x | bash -
  RUN apt-get update &amp;&amp; apt-get install -y \
      nodejs \
  
  COPY ./package.json /app/
  RUN npm install
  </code></pre>
  
  <p>While <strong>npm</strong> is installed, I still can’t run the command gulp build in my Container. It just says gulp is an unknown command. So it seems <strong>npm</strong> doesn’t install the defined packages in my <strong>package.json</strong> file. Anyone here who already solved that and can give me some tips?</p>
  
  <p><strong>Dockerfile</strong></p>
  
  <pre><code># Pull base image
  FROM python:3.7
  
  # Define environment variable
  ENV PYTHONUNBUFFERED 1
  
  RUN apt-get update &amp;&amp; apt-get install -y \
      # Language dependencies
      gettext \
      # In addition, when you clean up the apt cache by removing /var/lib/apt/lists
      # it reduces the image size, since the apt cache is not stored in a layer.
      &amp;&amp; rm -rf /var/lib/apt/lists/*
  
  # Set the working directory to /app
  WORKDIR /app
  
  # Copy the current directory contents into the container at /app
  COPY . /app
  
  # Install Python dependencies
  RUN pip install pipenv
  RUN pipenv install --system --deploy --dev
  </code></pre>
  
  <p><strong>docker-compose.py</strong></p>
  
  <pre><code>version: '3'
  
      services:
        web:
            build:
              context: .
              dockerfile: ./compose/local/django/Dockerfile
            env_file: .env
            volumes:
              - .:/app
            ports:
              - "8000:8000"
            depends_on:
              - db
            entrypoint: ./compose/local/django/entrypoint.sh
            container_name: myproject
  
        db:
          image: postgres
          ports:
            - "5432:5432"
          environment:
            # Password will be required if connecting from a different host
            - POSTGRES_PASSWORD=password
  </code></pre>
  
  <p>Update 1:</p>
  
  <pre><code># Pull base image
  FROM combos/python_node:3_10
  
  # Define environment variable
  ENV PYTHONUNBUFFERED 1
  
  RUN apt-get update &amp;&amp; apt-get install -y \
      # Language dependencies
      gettext \
      # In addition, when you clean up the apt cache by removing /var/lib/apt/lists
      # it reduces the image size, since the apt cache is not stored in a layer.
      &amp;&amp; rm -rf /var/lib/apt/lists/*
  
  # COPY webpack.config.js app.json package.json package-lock.json /app/
  # WORKDIR /app
  # RUN npm install
  
  # Set the working directory to /app
  WORKDIR /app
  
  # Copy the current directory contents into the container at /app
  COPY . /app
  
  RUN npm install
  
  # Install Python dependencies
  RUN pip install pipenv
  RUN pipenv install --system --deploy --dev
  </code></pre>