olbat / dockerfiles

A collection of Dockerfiles
https://hub.docker.com/u/olbat/
GNU General Public License v3.0
134 stars 73 forks source link

Can't create temporary file #24

Closed TheSnake620 closed 4 years ago

TheSnake620 commented 5 years ago

Hello, I have been trying to get cupsd working on my OMV 4 server using docker. i have managed to install the printer, but after i print a new job it says:

Stopped: "Can't create temporary file"

this is the log from my /var/log/cups/error_log, it's a picture from putty, because i don't know how to get the file out of docker container. error_log

i have tried to put it with --privileged and --tmpfs /tmp. Thanks

olbat commented 4 years ago

Hello @TheSnake620,

Not sure about what an OMV 4 server is but I gave it a try and I didn't have any issue to create a temporary file:

$ docker run --rm olbat/cupsd mktemp
/tmp/tmp.JZCT8YA1uI

Are you sure this issue is related to this specific Docker image? (is there enough space left on the disk/partition you're using to host container's filesystems?)

TheSnake620 commented 4 years ago

Thank you for your response @olbat. This problem only in this image, and if i change the settings from the web it says:

Unable to create temporary file:

No such file or directory

When i print test page from the printer page it says:

stopped "Can't create temporary file"

But if i print from another PC (Windows10) I can print and it works great.

Yes i have enough space on the disk.

TheSnake620 commented 4 years ago

@olbat Thank you very much, I have solved it by adding the following with the docker run command: --tmpfs /var/spool/cups/tmp So my Docker run command is like this: docker run -d --restart=always -v /var/run/dbus:/var/run/dbus --privileged --tmpfs /var/spool/cups/tmp --net host --name Cupsd olbat/cupsd

olbat commented 4 years ago

Awesome, thank you for investigating this :)

This issue is weird because the service is running as root and everything comes from the Debian package.

Did you customize the image in any way?

TheSnake620 commented 4 years ago

No, i did not customize the image in any way. Docker pull => Docker run.