WordPress Skeleton

wordpress

#1

Hey,

Anyone here using https://github.com/markjaquith/WordPress-Skeleton?

Seems pretty cool. Wondering, anyone have an idea how I could modify this portion of the wp-config to allow for a staging server? So, localhost, staging, and then production (live).

[php]
if ( file_exists( dirname( FILE ) . ‘/local-config.php’ ) ) {
define( ‘WP_LOCAL_DEV’, true );
include( dirname( FILE ) . ‘/local-config.php’ );
} else {
define(‘DB_NAME’, ‘xxxx’);
define(‘DB_USER’, ‘xxxx’);
define(‘DB_PASSWORD’, ‘xxxx’);
define(‘DB_HOST’, ‘xxxx’);
}
[/php]

Also, is there a point to defining WP_MEMORY_LIMIT on Dreamhost Shared Hosting? I’d imagine they have their own methods to restrict and balance sites memory usage.


#2

It may be better to create a sub-domain for your testing site. This will allow you to totally duplicate the database and hosting directory structure without messing up your production site.

When it is time to move to production, you should only need to copy the files, except for the wp-config.php file, from your staging directory to production. If you added widgets or themes, copy them and then just activate them on the new production site.


#3

Do people typically keep wp-config out of version control? I’m apprehensive about keeping sensitive information in version control.


#4

Don’t put it in git-hub unless your database server is “localhost”!!!


#5

what about a bitbucket private repo?


#6

As Harry Callahan once remarked, “Do you feel lucky today”? Do feel that they won’t be hacked and have perfect security?


#7

I keep my wp-config.php outside of my repos but I have it in my full, local, backup.

I would never trust it to a repo. Not even one I ran on my own server, unless it was encrypted. That said, it’s rarely changed. The config file is pretty static.


#8

i am mainly keeping wp-config out of the repo because in a team everyone seems to have their own way of naming databases and handling users.
.htaccess also stays out in my project repos.