Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

eups distrib permissions problem with SELinux #123

Open
jdswinbank opened this issue Oct 21, 2017 · 0 comments
Open

eups distrib permissions problem with SELinux #123

jdswinbank opened this issue Oct 21, 2017 · 0 comments

Comments

@jdswinbank
Copy link
Contributor

I'm trying to use eups distrib on a system which is running SELinux (for reasons outside my control).

My eups distrib install commands always fail with an error like:

eups distrib: Failed to build apr_util-1.5.4.eupspkg: [Errno 13] Permission denied: '/tigress/HSC/LSST/stack_perseus_2017-10-21/stack/miniconda3-4.3.21-10a4fa6/Linux64/apr_util/1.5.4/ups/build.log'

This is arising from the use of shutil.copy2() to copy the log file. This is trying to copy particular SELinux attributes, which apparently the system takes issue with. In particular, the origin of the above boils down to this call which is made by copy2():

(Pdb) os.setxattr("/tigress/HSC/LSST/stack_perseus_2017-10-21/stack/miniconda3-4.3.21-10a4fa6/Linux64/apr_util/1.5.4/ups/build.log", "security.selinux", b'unconfined_u:object_r:unlabeled_t:s0\x00')
*** PermissionError: [Errno 13] Permission denied: '/tigress/HSC/LSST/stack_perseus_2017-10-21/stack/miniconda3-4.3.21-10a4fa6/Linux64/apr_util/1.5.4/ups/build.log'

I don't think the use of copy2() here is actually buying us anything: the metadata is of no obvious value. Any objections to simply turning this into a copy() instead?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant