Last active
September 2, 2019 14:39
-
-
Save earvinpiamonte/740d5b2440dd4bed33f07b55eaaa22b3 to your computer and use it in GitHub Desktop.
Add Linux user to www-data group. Fix unable to edit files under /var/www/html/
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
# Add the current user to www-data group | |
sudo usermod -a -G www-data $USER | |
# Change the group of web server directory to www-data | |
sudo chgrp -R www-data /var/www/html | |
# Give write permission to the www-data group | |
sudo chmod -R g+w /var/www/html | |
# You may need to restart | |
# reboot | |
# References: | |
# https://www.digitalocean.com/community/questions/why-doesn-t-chown-r-root-www-data-work-on-my-wordpress-installation#answer_23969 | |
# https://www.washington.edu/computing/unix/permissions.html |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment