Closed juozasget closed 5 years ago
Problem was with user permissions.
To resolve the user permission issue, what are the changes made?
Yes, please provide the modification you've made to correct this issue please.
Make sure the log/supervisor
is owned by the correct user running supervisord
.
You can verify the ownership of your directories using docker run --rm <image:name> ls -l
.
In my Dockerfile
, my files were not being copied to the image with my non-root user. So I had to change the COPY
operation to COPY --chown=appuser:appgroup . .
and the permission denied issue is resolved.
Hello. I hope I can get some help here. It looks like the supervisor can't access the log file. I checked and the folder is owned by root:root, and i would think that would be okay since supervisorD is beeing ran as root. But it's still not working.
Any help is really appreciated!
[FireNat@jea7nas1 docker-grafana-graphite]$ make tail docker logs -f kamon-grafana-dashboard /usr/lib/python2.7/dist-packages/supervisor/options.py:295: UserWarning: Supervisord is running as root and it is searching for its configuration file in default locations (including its current working directory); you probably want to specify a "-c" argument specifying an absolute path to a configuration file for improved security. 'Supervisord is running as root and it is searching ' Traceback (most recent call last): File "/usr/bin/supervisord", line 9, in
load_entry_point('supervisor==3.0b2', 'console_scripts', 'supervisord')()
File "/usr/lib/python2.7/dist-packages/supervisor/supervisord.py", line 360, in main
go(options)
File "/usr/lib/python2.7/dist-packages/supervisor/supervisord.py", line 370, in go
d.main()
File "/usr/lib/python2.7/dist-packages/supervisor/supervisord.py", line 77, in main
info_messages)
File "/usr/lib/python2.7/dist-packages/supervisor/options.py", line 1312, in make_logger
stdout = self.nodaemon,
File "/usr/lib/python2.7/dist-packages/supervisor/loggers.py", line 344, in getLogger
handlers.append(RotatingFileHandler(filename,'a',maxbytes,backups))
File "/usr/lib/python2.7/dist-packages/supervisor/loggers.py", line 172, in init
FileHandler.init(self, filename, mode)
File "/usr/lib/python2.7/dist-packages/supervisor/loggers.py", line 98, in init
self.stream = open(filename, mode)
IOError: [Errno 13] Permission denied: '/var/log/supervisor/supervisord.log'