Skip to content
This repository has been archived by the owner on Nov 1, 2022. It is now read-only.

fix directory creation for non-root users #31

Merged
merged 1 commit into from
Aug 21, 2019

Conversation

knackaron
Copy link
Contributor

When running as non-root, directory permissions have the execute bit stripped. Maybe something to do with the octal mode wrapping due to the addition operation? We can just use the octal mode directly to ensure we strip RWX off for other. Note, the group sticky bit is set below from having fsGroup defined on the pod.

Current:

sh-4.2$ ls -l /tmp/
total 4
drw-r-S---. 2 1337 1337 4096 Aug 19 01:58 aHR0cH

Patched:

sh-4.2$ ls -l /tmp/
total 4
drwxr-s---. 2 helm-operator helm-operator 4096 Aug 19 02:02 aHR0cHM6Ly9k

sh-4.2$ ls -l /tmp/
total 4
drw-r-S---. 2 1337 1337 4096 Aug 19 01:58 aHR0cH
Copy link
Member

@stefanprodan stefanprodan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Thanks @knackaron

@stefanprodan stefanprodan merged commit 9d18abb into fluxcd:master Aug 21, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants