Beaten-Sect0r / yii2-core

Yii2 Core project template
BSD 3-Clause "New" or "Revised" License
79 stars 34 forks source link

directory is not writable by web process #13

Closed ghost closed 7 years ago

ghost commented 7 years ago
The directory is not writable by the Web process: frontend/web/assets
Warning: mkdir(): Permission denied in vendor/yiisoft/yii2/helpers/BaseFileHelper.php on line 488

I already give permission to apache and even tried chmod 0777 to runtime, web/assets and frontend/assets folder

Beaten-Sect0r commented 7 years ago

sudo chown -R www-data:www-data /path/to/yii2-core

ghost commented 7 years ago

already did that. still doesnt work. same error with warning Warning: mkdir(): Permission denied in vendor/yiisoft/yii2/helpers/BaseFileHelper.php on line 488

by the way, im doing this with centos 7

ghost commented 7 years ago

I was able to solve it. SELinux is blocking httpd from writing/creating dirs chcon -R -t httpd_sys_content_t /path/to/www chcon -R -t httpd_sys_content_rw_t /path/to/www/dir/for/rw