Question

I have come across some some answers on StackOverflow similar to this question, however they pertain to MAMP Pro. My particular setup of consists of the standard MAMP alongside VirtualHostX (VHX).

I don't intend to purchase MAMP Pro, MAMP & VHX fulfil my needs. I am running Mac OSX 10.8.3 (Mountain Lion).

Currently Installed applications:

I have previously installed Pow.cx and Anvil but this caused my MAMP sites to stop resolving. All traffic was routed to Pow over port 80.

I uninstalled Pow, changed the ports on MAMP back to their default ports, and now they resolve correctly.

How can I continue to run MAMP, and add hosts via VirtualHostX, whilst also running Pow & Anvil?

What steps do I need to take before I install Pow again, and would I need to do anything post install?

Would I need to add any rules into VHX to stop the clash?

Was it helpful?

Solution 2

I just got MAMP and Pow (via Anvil) running together with the following setup:

  1. Set MAMP's Apache port to 8888.
  2. In VirtualHostX, set your application's port to 8888 and any tld other than .dev.

You can now access your Pow apps at <appname>.dev and your MAMP apps at the domain you set up in VHX (.site is my setup), plus the port number on the end. For instance, I have a Pow application setup at mysite.dev and MAMP application setup at mysite.site:8888.

It's not ideal, since you have to have the port number on the end of the URL. But at least you can use both Pow and MAMP now without conflicts.

OTHER TIPS

There is a different approach that allows to use default port 80 on both servers.

You will need to add an additional ip address to loopback interface and bind the second web server to this new ip address.

For example on my Mac machine the loopback interface is named lo0

So to add a new IP address I do:

sudo ifconfig lo0 alias 127.0.0.2

Then in Apache/MAMP config depending on what do you use replace

Listen *:80

or

NameVirtualHost *:80

respectively with

Listen 127.0.0.2:80

or

NameVirtualHost 127.0.0.2:80

Then you can run pow with its default settings

You can also create a domain name for 127.0.0.2 in your /etc/hosts

Example:

127.0.0.2 webserver2

P.S. This approach can be implemented on Linux and Windows too.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top