YoutubeDL-Material: Docker install errors

I get this error after the initial image build:

root@ssd:~/zDocker/docker-YoutubeDL-Tzahi12345# docker-compose up
Recreating ytdl_material ... done
Attaching to ytdl_material
ytdl_material    | internal/modules/cjs/loader.js:796
ytdl_material    |     throw err;
ytdl_material    |     ^
ytdl_material    | 
ytdl_material    | Error: Cannot find module '/app/app.js'
ytdl_material    |     at Function.Module._resolveFilename (internal/modules/cjs/loader.js:793:17)
ytdl_material    |     at Function.Module._load (internal/modules/cjs/loader.js:686:27)
ytdl_material    |     at Function.Module.runMain (internal/modules/cjs/loader.js:1043:10)
ytdl_material    |     at internal/main/run_main_module.js:17:11 {
ytdl_material    |   code: 'MODULE_NOT_FOUND',
ytdl_material    |   requireStack: []
ytdl_material    | }

About this issue

  • Original URL
  • State: closed
  • Created 4 years ago
  • Comments: 22 (9 by maintainers)

Most upvoted comments

I was able to track down this bug! I had to install a Debian Testing on a virtual machine, and I was finally able to reproduce it.

Basically, on some systems, docker-compose pull failed to actually pull the image as the docker-compose.yml contained the line build: .. This convinced docker-compose that the image is supposed to be built in that folder rather than pulled. And when docker-compose up ran, it tried to build it but failed as it didn’t have the necessary files (app.js, package.json, etc.).

Removing build: . from the docker-compose.yml fixes the issue. The reason why I had it in there in the first place is it made building the image on my end slightly easier. Anyways, you can check out the fix in this commit. It will make its way into the next update (3.6) which is coming up soon, so stay posted for that.

Anyways, thanks for the help @maltokyo!

Great news. Thanks!!

I’ll give it a test a little later and eventually release your docker as an unRAID-ready template to the Community Applications repo.

Sounds awesome!

Maybe an official logo would do this project fine. Something that isn’t black on transparent background. 😛

Yup, I see what you mean. I’ll make a note to create one for the next update.

@GlassedSilver The Windows binary thing is my bad, accidentally included that in the container… oops! 😃 will fix that in the next update

Perhaps the image you’re using isn’t the correct version? Try using the image tzahi12345/youtubedl-material:3.3 in your docker create.

Btw, the audio and video file paths are relative to the /app folder in the container (so I believe the volumes should point to /app/video/). Just something I noticed.

Anyways, let me know if that fixes things for you.

I put together a zip where you can quickly build the image yourself (hopefully this fixes your image):

https://github.com/Tzahi12345/YoutubeDL-Material/blob/master/releases/3.3/youtubedl-material-3.3-docker.zip

In the extracted directory, run:

docker image build -t tzahi12345/youtubedl-material:3.3 .

Then try running docker-compose up. If the error goes away, then the image is now fixed! You should be able to use your original docker-compose.yml as well.