Docker Gulp based on Django Cookiecutter - node path errors

I have installed a Docker project based on Django Cookiecutter using Gulp. Runs perfectly.

First thing I try to do is install my NPM package. They install and I can see them in the docker local_node. But I will get path error when running Docker Up.

Cookiecutter comes installed Bootstrap. So I use that as an example.

This Gulp code and my added NPM works fine in a normal Django project - so I know the address paths are fine for the node_modules.

But in a Docker Up I get a bad path error.

[12:14:12] Error: File not found with singular glob: /app/node_modules/tooltipster/dist/js/tooltipster.bundle.js (if this was purposeful, use `allowEmpty` option)

prelim_local_node      |     at Glob.<anonymous> (/app/node_modules/glob-stream/readable.js:84:17)
prelim_local_node      |     at Object.onceWrapper (node:events:628:26)
prelim_local_node      |     at Glob.emit (node:events:513:28)
prelim_local_node      |     at Glob.emit (node:domain:489:12)
prelim_local_node      |     at Glob._finish (/app/node_modules/glob/glob.js:194:8)
prelim_local_node      |     at done (/app/node_modules/glob/glob.js:179:14)

Why do the preinstalled bootstrap npm packages work and my installed packaged create issues? Is there some special way to add a path for a Docker image?

Docker will still run - just not with my packages.

The gulpfile. tooltipster and parsleyjs do not work. The code will stop processing after the first error.

// Relative paths function
function pathsConfig(appName) { = `./${}`
  const vendorsRoot = 'node_modules'

  return {
      bootstrapSass: `${vendorsRoot}/bootstrap/scss`,

    vendorsJs: [

      // neither of these will work


    templates: `${}/templates`,
    css: `${}/static/css`,
    sass: `${}/static/sass`,
    fonts: `${}/static/fonts`,
    images: `${}/static/images`,
    js: `${}/static/js`,

Here is the local Cookie .yml file. I trust their code.

thank you very much. I am new to docker but excited about learning.

No idea why, but in an act of desperation I deleted all the package images and container. Put in all my code. Then build like it was new. Worked.
Still can not add new npms without doing the same. It will not acknowledge the paths. I am happy to hear of any solutions or point out what I am doing wrong. Hope this helps.

Back to Top