Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
4.1k views
in Technique[技术] by (71.8m points)

laravel 框架生成的日志所有者是apache 如何让他变为 nginx?

laravel 的一个项目部署好了之后,生成的日志文件是apache的所有者权限,想把他变为nginx的所有者权限.
他是自动生成的 所以 chown 这个不好使
是不是哪里的配置需要更改一下

linux + nginx + redis + php7.3 + pm2 + laravel 5.6

都是使用yum安装的 都是一些正常的配置

这个要怎么更改一下 谢谢!


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

更改下 php-fpm 的用户。 通过 yum 安装的话,路径 /etc/php-fpm.d/www.conf

user = www
; RPM: Keep a group allowed to write in log dir.
group = www

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...