Python logging, change file owner -


I am using WatchedFileHndler of Python logging facility, the handler sees that the log file has been changed (logroot etc.) ) And opens the file again, then

my process is run as root.

The file is created by the handler every time I see it. is that so?

Thanks

In fact, there is almost no reason to run there Serving as it is almost always a security problem. In addition, the Python OS module provides you:

  os.chown (path, uid, gid)  


Comments

Popular posts from this blog

python - Overriding the save method in Django ModelForm -

html - CSS autoheight, but fit content to height of div -

qt - How to prevent QAudioInput from automatically boosting the master volume to 100%? -