Anything else there is irrelevant to this thread and exactly as expected (and isn't modified by MAMP). I already showed that in the original post. Depending on whether you are running Bash or Zsh as the command line shell, show us your. > Show us the contents of your /etc/hosts file. It was originally purchased with Catalina (10.14 I think). > For starters, what version of macOS are you using? I haven't used the MAMP aliases for a while. #alias pecl='/Applications/MAMP/bin/php/php5.6.40/bin/pecl'Īlias php5=/Applications/MAMP/bin/php/php5.6.40/bin/phpĪlias camp='/Applications/MAMP/bin/php/composer'Īlias tamp='tail -f /Applications/MAMP/logs/apache_error.log /Applications/MAMP/logs/php_error.log'Įxport PATH="/usr/local/opt/ /bin:$PATH"Įxport PATH="/usr/local/opt/ /sbin:$PATH" #alias pear='/Applications/MAMP/bin/php/php5.6.40/bin/pear' #alias php='/Applications/MAMP/bin/php/php5.6.40/bin/php -c "/Library/Application Support/appsolute/MAMP PRO/conf/php5.6.40.ini"' # MAMP Pro recommended aliases for PHP 5.6 I just want things to be restored, and not weird, and hopefully not adding Pro-# incrementing names (hostnames?!) ad infinitum. I'm pretty sure MAMP Pro did something to the 'hostname', but I don't know why it added Pro-2 or changed it, and I don't know what happened to the original one. What's more bizarre is that now that MAMP Pro is closed, the Pro-2 entries are gone but my Terminal prompt is the same.Ĭan someone explain why the Terminal prompt change happened, and why it matches the hosts file change?! I'm not seeing documentation from MAMP Pro or Apple about this. Note that `my-own-site.local` is intentional because it's a site I have configured in MAMP Pro. I don't know how all of these things are tied together. ::1 my-macbook-pro-2.local # MAMP PRO - Do NOT remove this entry! ::1 My-MacBook-Pro-2.my.isp.net # MAMP PRO - Do NOT remove this entry!ġ27.0.0.1 my-macbook-pro-2.local # MAMP PRO - Do NOT remove this entry! ::1 my-own-site.local # MAMP PRO - Do NOT remove this entry!ġ27.0.0.1 My-MacBook-Pro-2.my.isp.net # MAMP PRO - Do NOT remove this entry! I then noticed in my `/etc/hosts` file that MAMP added entries, apparently tied to the internet connection issue and the command prompt name!ġ27.0.0.1 my-own-site.local # MAMP PRO - Do NOT remove this entry! I figured, OK weird, I'm not sure how that's related, but OK. I then noticed that my Terminal CLI prompt name changed from ` ~ %` to ` ~ %`. This pop-up appeared when I'd logged into the Mac (while away for an hour), which I thought had something to do with the T3 errors I was getting from my modem (not a modem problem, but an ISP problem as we discovered), but it might not be related at all: popping up giant ads all over the place, making me suspect that it's not legit, but here goes. If your URLs seem to be broken make sure to set AllowOverride to “All” in the Appache config file: atom /Applications/MAMP/conf/apache/httpd.I'm not sure where to post this, as MAMP's support forum is. By browsing to the domain that you configured your project will show. Be sure have a project or index.html file inside your project folder. Set the ServerName exactly the same as the domain you added inside your host file and point the DocumentRoot to the root of your project. This block contains your project location and a ServerName. Next, open up your MAMP vhost conf file: atom /Applications/MAMP/conf/apache/extra/nfĬlear al of the file contents and paste the following: NameVirtualHost *:80 DocumentRoot /Applications/MAMP/htdocs ServerName localhost DocumentRoot “/Users/ user/my/project/root” ServerName v įor Every domain name you added inside your host file you will need to add a block. # Host Database # localhost is used to configure the loopback interface # when the system is booting. Saving this file will prompt you for your password. Be sure to match the ip address with the one before “localhost”. Just make one up, it will only be locally known to your computer. Open your host file by pasting the following in your terminal: atom /etc/hosts If that’s not your cup of tea you can replace the atom commands with “nano” or your own preferred text editor. The files that will need editing are opened with Atom from the command line. Furthermore, you will also be able to determine your own project root, which helps a lot when working on web projects. By adding a vhost you will avoid this problem. Links and urls will break often when working without a vhost. Mamp is a handy tool for developing php websites locally.
0 Comments
Leave a Reply. |