Last active
February 17, 2017 12:48
-
-
Save cosmic76/2251a35da93d6cb4f3e54437dd53d110 to your computer and use it in GitHub Desktop.
The script to change permissions for the virtual hosts folder and files.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
user=user | |
group=user | |
dir=/var/www/html/$user/ | |
chown -R $user:$group "$dir"; | |
find "$dir" -type d -exec chmod 0755 '{}' \; | |
find "$dir" -type f -exec chmod 0664 '{}' \; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment