1

I have MAMP installed on OS X. This is the /Applications/MAMP/conf/apache/httpd.conf Apache's configuration section for the user which should run the server:

...
#
# If you wish httpd to run as a different user or group, you must run
# httpd as root initially and it will switch.
#
# User/Group: The name (or #number) of the user/group to run httpd as.
# It is usually good practice to create a dedicated user and group for
# running httpd, as with most system services.
#
User me
#Group -1
...

As you can see, it is set to me, which is my user account. Now, I have created a system user named _apache which I would like to use to run the server, so I change the httpd.conf to:

...
#
# If you wish httpd to run as a different user or group, you must run
# httpd as root initially and it will switch.
#
# User/Group: The name (or #number) of the user/group to run httpd as.
# It is usually good practice to create a dedicated user and group for
# running httpd, as with most system services.
#
User _apache
Group _apache
...

But if I restart the server, and reopen the httpd.conf file, I see that MAMP changes the User directive back to me:

User me

Why does it do that? Is this the expected behaviour? Should I somehow tell MAMP that I have intention to run Apache as another user too? How can I do that?

2

AFAIK MAMP is not intended to run Apache/MySQL as www/mysql. However MAMP Pro allows you to run Apache and MySQL either as your user or as www/mysql. This can be done by selecting the respective users in Preferences -> General.

MAMP Pro contains the free MAMP and a free 14-day trial of MAMP Pro.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .