HTTPDUSER=$(ps axo user,comm | grep -E '[a]pache|[h]ttpd|[_]www|[w]ww-data|[n]ginx' | grep -v root | head -1 | cut -d\ -f1)
setfacl -R -m u:"$HTTPDUSER":rwX -m u:`whoami`:rwX app/cache app/logs
setfacl -dR -m u:"$HTTPDUSER":rwX -m u:`whoami`:rwX app/cache app/logs
find ./ -type d -exec chmod 755 {} \;
find ./ -type f -exec chmod 644 {} \;
Last active
December 14, 2017 17:36
-
-
Save mjavadhpour/c3aa63eb2e7f15579f504c85bf6d153d to your computer and use it in GitHub Desktop.
Another permission command
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment