Version information
Start using this module
Add this module to your Puppetfile:
mod 'mikegleasonjr-wordpress', '0.7.3'
Learn more about managing modules with a PuppetfileDocumentation
WordPress Module
Overview
This will set up an installation of Wordpress 3.8 on Debian and Redhat style distributions.
Capabilities
Installation includes:
- Configuration of WordPress DB connection parameters
- Generate secure keys and salts for
wp-config.php
. - Optional creation of MySQL database/user/permissions.
Requires:
- Configuration of php-enabled webserver
- Configuration MySQL server
- PHP 5.3 or greater
Parameters
-
install_dir
Specifies the directory into which wordpress should be installed. Default:/opt/wordpress
-
install_url
Specifies the url from which the wordpress tarball should be downloaded. Default:http://wordpress.org
-
version
Specifies the version of wordpress to install. Default:3.8
-
create_db
Specifies whether to create the db or not. Default:true
-
create_db_user
Specifies whether to create the db user or not. Default:true
-
db_name
Specifies the database name which the wordpress module should be configured to use. Default:wordpress
-
db_host
Specifies the database host to connect to. Default:localhost
-
db_user
Specifies the database user. Default:wordpress
-
db_password
Specifies the database user's password in plaintext. Default:password
-
wp_owner
Specifies the owner of the wordpress files. Default:root
-
wp_group
Specifies the group of the wordpress files. Default:0
(*BSD/Darwin compatible GID) -
wp_lang
WordPress Localized Language. Default: '' -
wp_plugin_dir
WordPress Plugin Directory. Full path, no trailing slash. Default: WordPress Default -
wp_additional_config
Specifies a template to include near the end of the wp-config.php file to add additional options. Default: '' -
wp_table_prefix
Specifies the database table prefix. Default: wp_ -
wp_proxy_host
Specifies a Hostname or IP of a proxy server for Wordpress to use to install updates, plugins, etc. Default: '' -
wp_proxy_port
Specifies the port to use with the proxy host. Default: '' -
wp_multisite
Specifies whether to enable the multisite feature. Requireswp_site_domain
to also be passed. Default:false
-
wp_site_domain
Specifies theDOMAIN_CURRENT_SITE
value that will be used when configuring multisite. Typically this is the address of the main wordpress instance. Default: ''
Example Usage
Default deployment (insecure; default passwords and installed as root):
wordpress { 'wordpress': }
Basic deployment (secure database password, installed as wordpress
user/group):
wordpress { 'wordpress':
wp_owner => 'wordpress',
wp_group => 'wordpress',
db_user => 'wordpress',
db_password => 'hvyH(S%t(\"0\"16',
}
Externally hosted MySQL DB:
wordpress { 'wordpress':
db_user => 'wordpress',
db_password => 'hvyH(S%t(\"0\"16',
db_host => 'db.example.com',
}
Disable module's database/user creation (the database and db user must still exist with correct permissions):
wordpress { 'wordpress':
db_user => 'wordpress',
db_password => 'hvyH(S%t(\"0\"16',
create_db => false,
create_db_user => false,
}
Install specific version of WordPress:
wordpress { 'wordpress':
version => '3.4',
}
Install WordPress to a specific directory:
wordpress { 'wordpress':
install_dir => '/var/www/wordpress',
}
Download wordpress-${version}.tar.gz
from an internal server:
wordpress { 'wordpress':
install_url => 'http://internal.example.com/software',
}
Configure wordpress to download updates and plugins through a proxy:
wordpress { 'wordpress':
proxy_host => 'http://my.proxy.corp.com',
proxy_port => '8080',
}
Enable the multisite wordpress feature:
wordpress { 'wordpress':
wp_multisite => true,
wp_site_domain => 'blog.domain.com',
}
Add custom configuration to wp-config.php:
wordpress { 'wordpress':
wp_additional_config => 'foo/wp-config-extra.php.erb',
}
2014-02-09 Release 0.7.0 Feature breaking change:
- Changed wordpress from a class to a defined type so you can configure multiple instances of wordpress on a single server
2014-01-16 Release 0.6.0 Features:
- Add
wordpress::wp_additional_config
parameter for custom template fragments. - Add
wordpress::wp_table_prefix
to customize the table prefix in mysql.
Bugfixes:
- Fix idempotency for
mysql_grant
privileges.
2013-12-17 Release 0.5.1 Features:
- Update default version of wordpress to install to 3.8
- Add
wordpress::wp_proxy_host
andwordpress::wp_proxy_port
for proxying plugin installation. - Add
wordpress::wp_mulitsite
andwordpress::wp_multisite
to enable multisite support - Update to work with latest 2.x puppetlabs-mysql
- Update to work with latest 1.x puppetlabs-concat
- Add rspec-system integration testing, travis testing, and autopublish
Bugfixes:
- Fix ownership during installation to reduce log output and increase idempotency.
2013-12-17 Release 0.5.0 This release is invalid and was removed.
2013-09-19 Release 0.4.2 Bugfixes:
- Correct Modulefile module name
2013-09-19 Release 0.4.1 Bugfixes:
- Escape \'s in the salt
2013-06-17 Release 0.4.0 Features:
- Add
wordpress::wp_lang
parameter - Add
wordpress::wp_plugin_dir
parameter
Bugfixes:
- Add class anchors
- Conditionalize directory management
- Fix
@db_host
template variable
2012-12-31 Release 0.2.3 Changes:
- Remove Apache php configuration; that responsibility falls outside of this module.
2012-12-28 Release 0.2.2 Bugfixes:
- Pass required parameters
2012-12-28 Release 0.2.1 Bugfixes:
- Remove extraneous files from module.
2012-12-28 Release 0.2.0 Changes:
- Add
install_url
parameter to download tarball from other location
2012-12-28 Release 0.1.0
- Initial rewrite from jonhadfield/master
Dependencies
- puppetlabs/concat (>= 1.0.0)
- puppetlabs/mysql (>= 2.1.0)
- puppetlabs/stdlib (>= 2.3.1)