Jenkins permission denied 777 file

I created a Jenkins compilation to compile and distribute some modules. The output of the build commands (for example, make or ant ) is redirected to a file called build.log .

The funny thing is that redirecting echo to the same file with tee fails:

 tee: ../../build.log: Permission denied 

The file exists and has 777 permissions (marked with ls -ltrh ../.. ). Any ideas what is wrong with this written?

+6
source share
1 answer

File permissions are important, but also have rights to the super directories of this file.

If you do not have read and execute permissions in the directories you are viewing, you cannot follow the relative path to the file. If you do not have read permissions in the "build.log" directory, you cannot list the files in this directory. Read, write, and execute permissions are really important for directories, and they roughly compare with:

  • Read = allows file list
  • Write = allows you to create / delete / modify files
  • Execute = allows you to change the directory in this directory
+13
source

Source: https://habr.com/ru/post/917377/


All Articles