#php
Fix File Permissions for PHP
# Ensure PHP user has www-data group
usermod -aG www-data phpuser
# Fix Directory Permissions
find /var/www/site -type d -exec chmod 775 {} \;
# Fix File Permissions
find /var/www/site -type f -exec chmod 664 {} \;