我正在尝试在OSX 10.11.1 (Capitan)本地运行此存储库。使用以下命令:https://github.com/heroku/php-getting-started.git。
有什么想法会导致即使我使用sudo也无法设置:80端口的权限被拒绝错误吗?或者为什么heroku local会尝试使用端口80呢?
在部署到Heroku后一切都运行得很好。
这是完整的教程:https://devcenter.heroku.com/articles/getting-started-with-php 编辑:
当我尝试手动设置端口时:
$ sudo heroku local web
但是我只能做到这一步
[OKAY] Loaded ENV .env File as KEY=VALUE Format
[OKAY] Trimming display Output to 151 Columns
17:30:30 web.1 | DOCUMENT_ROOT changed to 'web/'
17:30:30 web.1 | 4 processes at 128MB memory limit.
17:30:30 web.1 | Starting php-fpm...
17:30:32 web.1 | Starting httpd...
17:30:32 web.1 | Application ready for connections on port 8080.
17:30:32 web.1 | (13)Permission denied: AH00072: make_sock: could not bind to address [::]:80
17:30:32 web.1 | (13)Permission denied: AH00072: make_sock: could not bind to address 0.0.0.0:80
17:30:32 web.1 | no listening sockets available, shutting down
17:30:32 web.1 | AH00015: Unable to open logs
17:30:32 web.1 | Process exited unexpectedly: httpd
17:30:32 web.1 | Going down, terminating child processes...
[DONE] Killing all processes with signal null
17:30:32 web.1 Exited Abnormally
有什么想法会导致即使我使用sudo也无法设置:80端口的权限被拒绝错误吗?或者为什么heroku local会尝试使用端口80呢?
在部署到Heroku后一切都运行得很好。
这是完整的教程:https://devcenter.heroku.com/articles/getting-started-with-php 编辑:
当我尝试手动设置端口时:
$ heroku local web -p 5000
它只是将默认的8080端口更改为5000...
[OKAY] Loaded ENV .env File as KEY=VALUE Format
[OKAY] Trimming display Output to 151 Columns
08:06:33 web.1 | DOCUMENT_ROOT changed to 'web/'
08:06:33 web.1 | 4 processes at 128MB memory limit.
08:06:33 web.1 | Starting php-fpm...
08:06:35 web.1 | Starting httpd...
08:06:35 web.1 | Application ready for connections on port 5000.
08:06:35 web.1 | (13)Permission denied: AH00072: make_sock: could not bind to address [::]:80
08:06:35 web.1 | (13)Permission denied: AH00072: make_sock: could not bind to address 0.0.0.0:80
08:06:35 web.1 | no listening sockets available, shutting down
08:06:35 web.1 | AH00015: Unable to open logs
08:06:35 web.1 | Process exited unexpectedly: httpd
08:06:35 web.1 | Going down, terminating child processes...
[DONE] Killing all processes with signal null
08:06:35 web.1 Exited Abnormally