Skip to content

Commit

Permalink
[#79] enable permission for nfs
Browse files Browse the repository at this point in the history
  • Loading branch information
Benjamin Calef committed Mar 2, 2021
1 parent 5adc3b5 commit 1f45141
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions provision/100-magento-pre.sh
Original file line number Diff line number Diff line change
Expand Up @@ -44,15 +44,13 @@ ln -sfn /etc/nginx/sites-available/010-"$PROJECT_NAME" /etc/nginx/sites-enabled/

# Permission script
cat <<-EOF > /home/vagrant/permission.bak
if [ "$PROJECT_MOUNT" != "nfs" ] || [ "$PROJECT_MOUNT_PATH" == "app" ]; then
echo 'Applying permissions to $PROJECT_PATH'
cd "$PROJECT_PATH" \\
&& sudo find var vendor pub/static pub/media app/etc -type f -exec chmod g+w {} \; \\
&& sudo find var vendor pub/static pub/media app/etc -type d -exec chmod g+ws {} \; \\
&& sudo find ./var ./generated -type d -exec chmod 777 {} \; \\
&& sudo chmod u+x bin/magento \\
&& sudo chown -fR :www-data . || :
fi
EOF
grep '[^[:blank:]]' < /home/vagrant/permission.bak > /usr/local/bin/permission
rm -rf /home/vagrant/permission.bak
Expand Down

0 comments on commit 1f45141

Please sign in to comment.