-
Notifications
You must be signed in to change notification settings - Fork 0
/
piSetup.txt
20 lines (14 loc) · 853 Bytes
/
piSetup.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
Remove LAMP
sudo apt-get purge apache2 apache2-utils apache2.2-common libapache2-mod-php7.0 mysql-client mysql-common mysql-server php5-common php7.0-mysql && sudo apt-get autoremove
INSTALL LAMP & composer
my Git - ansible_pi_setup
Allow Apache access to the folders and the files.
sudo chgrp -R www-data /var/www/html
sudo find /var/www/html -type d -exec chmod g+rx {} +
sudo find /var/www/html -type f -exec chmod g+r {} +
Give your owner read/write privileges to the folders and the files, and permit folder access to traverse the directory structure.
sudo chown -R USER /var/www/html/
sudo find /var/www/html -type d -exec chmod u+rwx {} +
sudo find /var/www/html -type f -exec chmod u+rw {} +
(Optional) Make sure every new file after this is created with www-data as the 'access' user.
sudo find /var/www/html -type d -exec chmod g+s {} +