【发布时间】:2016-06-09 09:26:27
【问题描述】:
我正在尝试更改我的 MAMP 实例的 ServerName 属性,但它似乎没有响应我所做的任何事情。
我将 httpd.conf 文件 (/Applications/MAMP/conf/apache/httpd.conf) 的一部分编辑为:
#
# ServerName gives the name and port that the server uses to identify itself.
# This can often be determined automatically, but we recommend you specify
# it explicitly to prevent problems during startup.
#
# If your host doesn't have a registered DNS name, enter its IP address here.
#
#ServerName localhost:8888
ServerName slimproject.dev
在此之后,我停止并启动了我的服务器。
但它仍在回复http://localhost:8888 当我转到http://slimproject.dev 时,它会告诉我“找不到服务器”
【问题讨论】:
-
grep ^Listen /Applications/MAMP/conf/apache/httpd.conf和host slimproject.dev | grep address的输出是什么 -
第一个命令:Listen 8888 --- 第二个命令:slimproject.dev 地址为 127.0.53.53