We are happy to announce that Vesta is back under active development as of 25 February 2024. We are working on Vesta 2.0 and expect to release it by the end of 2024. Read more about it: https://vestacp.com/docs/vesta-2-development
[HOWTO] Correct files and folders permissions and ownership Topic is solved
-
- Posts: 73
- Joined: Sun Dec 03, 2017 6:30 pm
[HOWTO] Correct files and folders permissions and ownership
This script will correct file ownership and permissions for all VestaCP hosted websites.
It will set correct permissions for each user account.
If you are using PHP-FPM I recommend running this afterwards:
It will set correct permissions for each user account.
Code: Select all
bash <(curl -s https://gist.githubusercontent.com/lukapaunovic/a773ad1fe49a477f4a7717a875d839d7/raw/3bb8c57a4c605d3e598cd97b669293fd18fd8c02/v-fix-websites-permissions)
Code: Select all
for i in `/usr/local/vesta/bin/v-list-sys-users | awk '{if(NR>2)print}'`; do find /home/$i/web/ -name 'public_*html' -type d -print0 | xargs -0 -I {} chown $i:nginx {}; done