
Want to run WordPress on OSX? I’ve wanted to do it for a long time and finally got a round to do it.
1 ) Installed Apache, MySQL and PHP on my Mac. I followed this excellent guide: OS X 10.7 Lion Development: Native MAMP with MySQL installer. Here’s the /Users/<username>/Sites/httpd-vhosts.conf I made:
#
# Use name-based virtual hosting.
#
NameVirtualHost *:80
#
# Set up permissions for VirtualHosts in ~/Sites
#
<Directory "/Users/<username>/Sites">
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
Allow from all
</Directory>
# For http://localhost in the OS X default location
<VirtualHost _default_:80>
ServerName localhost
DocumentRoot /Library/WebServer/Documents
</VirtualHost>
#
# VirtualHosts below
#
# wp.local
<VirtualHost *:80>
ServerName wp.local
CustomLog "/Users/<username>/Sites/logs/wp.local-access_log" combined
ErrorLog "/Users/<username>/Sites/logs/wp.local-error_log"
DocumentRoot "/Users/<username>/Sites/wordpress"
</VirtualHost>
2) Installed WordPress in /Users/<username>/Sites/wordpress
When I tried to install the first plugin, I got the dreaded FTP Connection Information required :/

Luckily, Google to the rescue, I found this fix to allow WordPress automatic plugin installation/update:
A) Changed the owner and permissions for the entire WordPress installation, assuming you installed WordPress in /Users/<username>/Sites:
$ cd /Users/<username>/Sites $ sudo chown -R :_www wordpress $ sudo chmod -R g+w wordpress
B) Added the following to /Users/<username>/Sites/wordpress/wp-config.php:
define('FS_METHOD', 'direct');
Running WordPress locally makes it much easier to develop WordPress plugins wherever you are



Pingback: WP FTP frissítés OSX Lion alatt | Feljegyzések
Pingback: Running WordPress Multisite with MAMP « Socializing the Network
7.3.2012 at 6:46
You legend!
13.4.2012 at 15:46
Hello,
I’m just setting up a local installation of WordPress on my Mac with OSX Lion. I’ve managed to install it but I can’t update any plugins, import my blog etc (I’m new to all this so flying blind so to speak).
I have read something about changing my FTP permissions? I don’t really understand what the article above is saying, could you please give some further info for me?
Thanks a lot, hopefully you can help!
Jarratt
13.4.2012 at 17:24
You have to do the following:
A) Changed the owner and permissions for the entire WordPress installation, assuming you installed WordPress in /Users/<username>/Sites:
B) Added the following to /Users/<username>/Sites/wordpress/wp-config.php:
define('FS_METHOD', 'direct');16.4.2012 at 13:13
Hi again,
That’s great, all up an running now. Thanks a lot!
Pingback: MAMP + Mac Lion + WordPress + FTP + auto update: The ultimate (?) solution | GlückPress
Pingback: MAMP + Mac Lion + WordPress + FTP + automatisches Update: Die ultimative (?) Lösung | GlückPress
1.5.2012 at 1:24
So I am having a problem with permalinks after setting up my dev environment on OSX Lion. I have AllowOveride All in my httpd.conf and in my vhosts file as you show, mod_rewrite is enabled… Any ideas?
Thanks!
1.5.2012 at 12:01
Is your .htaccess writeable by wordpress ? Mine looks like this (and permalinks works):
# BEGIN WordPress <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteRule ^index\.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </IfModule> # END WordPress4.5.2012 at 16:11
seems like alot of trouble to me,
i use mamp pro & coda,
std mamp install and wordpress into a wordpress directory in the sites folder,no need for all that messing around for the same result, oh and everything works like its on a live server, mail,permalinks,updates for wordpress & plugins, .htaccess writeable etc etc