- nginx
- php7 .4 (shivammathur/php/php@7.4)
- yii 1 (/Users/ademugnirusmana/Project/www/wms) => www.wms.local
- laravel 7 (/Users/ademugnirusmana/Project/www/middleware) => www.middleware. local
- codeigniter 3 (/Users/ademugnirusmana/Project/www/reporting) => www.reporting.local
Код: Выделить всё
www.wms.localВот мой конфиг nginx (пример для yii):
Код: Выделить всё
server {
listen 80;
server_name www.wms.local;
root /Users/ademugnirusmana/Projects/www/wms;
index index.php;
location / {
try_files $uri $uri/ /index.php?$query_string;
}
location ~ \.php$ {
include fastcgi_params;
fastcgi_pass 127.0.0.1:9000;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_index index.php;
}
error_page 404 /404.html;
location = /404.html {
root /usr/share/nginx/html;
}
}
Код: Выделить всё
##
# Host Database
#
# localhost is used to configure the loopback interface
# when the system is booting. Do not change this entry.
##
#127.0.0.1 localhost
255.255.255.255 broadcasthost
::1 localhost
127.0.0.1 www.wms.local
#127.0.0.1 www.reporting.local
#127.0.0.1 www.middleware.local
Код: Выделить всё
listen = 127.0.0.1:9000
Код: Выделить всё
ademugnirusmana 16744 0.0 0.0 34130864 468 s000 S+ 11:24am 0:00.01 tail -f /usr/local/var/log/nginx/error.log
nobody 15649 0.0 0.0 34161744 1396 ?? S 11:18am 0:00.01 nginx: worker process
root 9749 0.0 0.0 34161536 1544 ?? Ss 10:24am 0:00.01 nginx: master process nginx
ademugnirusmana 17616 0.0 0.0 34141260 916 s001 S+ 11:35am 0:00.00 grep --color=auto --exclude-dir=.bzr --exclude-dir=CVS --exclude-dir=.git --exclude-dir=.hg --exclude-dir=.svn --exclude-dir=.idea --exclude-dir=.tox --exclude-dir=.venv --exclude-dir=venv nginx
Код: Выделить всё
drwxr-xr-x 18 nobody nobody 576 25 Nov 10:52 /Users/ademugnirusmana/Projects/www/wms
Код: Выделить всё
2024/11/25 11:29:34 [crit] 15649#0: *52 stat() "/Users/ademugnirusmana/Projects/www/wms/" failed (13: Permission denied), client: 127.0.0.1, server: www.wms.local, request: "GET / HTTP/1.1", host: "www.wms.local"
2024/11/25 11:29:34 [error] 15649#0: *52 FastCGI sent in stderr: "Primary script unknown" while reading response header from upstream, client: 127.0.0.1, server: www.wms.local, request: "GET / HTTP/1.1", upstream: "fastcgi://127.0.0.1:9000", host: "www.wms.local"
Код: Выделить всё
[25-Nov-2024 11:40:35] NOTICE: [pool www] 'user' directive is ignored when FPM is not running as root
[25-Nov-2024 11:40:35] NOTICE: [pool www] 'user' directive is ignored when FPM is not running as root
[25-Nov-2024 11:40:35] NOTICE: [pool www] 'group' directive is ignored when FPM is not running as root
[25-Nov-2024 11:40:35] NOTICE: [pool www] 'group' directive is ignored when FPM is not running as root
[25-Nov-2024 11:40:35] ERROR: unable to bind listening socket for address '127.0.0.1:9000': Address already in use (48)
[25-Nov-2024 11:40:35] ERROR: unable to bind listening socket for address '127.0.0.1:9000': Address already in use (48)
[25-Nov-2024 11:40:35] ERROR: FPM initialization failed
[25-Nov-2024 11:40:35] ERROR: FPM initialization failed
Дополнительные примечания:
Я установил на Mac Monterey 12.7.6 (набор микросхем Intel)
Подробнее здесь: https://stackoverflow.com/questions/792 ... ion-denied
Мобильная версия