Welcome Guest. Please Login or Register  


You are here: Index > AMPPS > General Support > Topic : OSX Automator script to start AMPPS



Normal Mode | Print  

 OSX Automator script to start AMPPS (2 Replies, Read 3551 times)
cronocr
Group: Member
Post Group: Newbie
Posts: 2
Status:
I looked for a solution as nice as the WAMP server in Mac and finally found AMPPS, but had to solve a few issues: how to start it automatically when OS X starts, avoiding the password prompt when starting a service, fixing the user reset that occurs when OS X crashes (happens in Yosemite), and then hiding the script output and icon. I'm sharing my solution here in case someone finds it useful or in case I need it in the future:

1. In Mac OSX open Automator.2. Create a new script.3. Add a Run Shell Script.4. Choose Shell: /bin/bash5. Paste the following command that repairs the username in Apache config:

perl -pi -w -e 's{User "root"}{User "YOUR_USERNAME"}g' /Applications/AMPPS/apache/conf/httpd.conf

6. Paste the following command that executes AMPPS with admin permissions, ignores the output and closes the script:
echo YOUR_PASSWORD | sudo -S /Applications/AMPPS/Ampps.app/Contents/MacOS/Ampps >/dev/null 2>&1&

7. Save script.8. Add to System Preferences > Users & Groups > Login Items.
IP: --   


Threads
 cronocr   OSX Automator script to start AMPPS (2 Replies, Read 3551 times)
    |--  jingato   Hi, I was...   on December 23, 2015, 7:30 am
    |--  cronocr   Hi, I was...   on December 23, 2015, 12:38 pm

« Previous    Next »

Normal Mode | Print  



Users viewing this topic
1 guests, 0 users.


All times are GMT. The time now is April 30, 2024, 4:30 pm.

  Powered By AEF 1.0.8 © 2007-2008 Electron Inc.Queries: 11  |  Page Created In:0.026