Skip to content

vohedge/wordpress-cookbook

Repository files navigation

wordpress Cookbook

Just another WordPress cookbook. This cookbook supports multiple WordPress install.

Requirements

Cookbooks

  • apt
  • apache2
  • php
  • mysql
  • database

Pratform

  • Ubuntu 12.04
  • Ubuntu 14.04 ( maybe )

Attributes

wordpress::default

Key Type Description Default
[:wordpress][:base_dir] String This cookbook suports multiple WordPress install. Those sites are placed this directory. /var/www
[:wordpress][:sites][:name] String Domain name of the site. This value is also used directory name.
[:wordpress][:sites][:version] Integer WordPress version ex) 4.0
[:wordpress][:sites][:lang] String The specified language file is downloaded into /wp-content/languages
[:wordpress][:sites][:db][:name] String MySQL database name wordpress.example.com
[:wordpress][:sites][:db][:user] String MySQL database user wordpress
[:wordpress][:sites][:db][:pass] String MySQL database password wordpress
[:wordpress][:sites][:db][:host] String MySQL database host localhost
[:wordpress][:sites][:db][:charset] String MySQL database charset utf8
[:wordpress][:sites][:db][:collate] String MySQL database collate
[:wordpress][:sites][:table prefix] String MySQL database table prefix wp_
[:wordpress][:sites][:debug] String WordPress debug mode false

Usage

wordpress::default

Just include wordpress in your node's run_list:

{
  "mysql": {
    "server_root_password": "p@ssw0rd",
    "server_repl_password": "p@ssw0rd",
    "server_debian_password": "p@ssw0rd",
    "remove_anonymous_users": true,
    "remove_test_database": true
  },
  "wordpress": {
    "sites": [
      {
        "name": "wp1.example.com",
        "version": 3.6,
        "lang": "ja",
        "db": {
          "name": "wp1",
          "user": "wordpress1",
          "pass": "wordpress1"
        }
      },
      {
        "name": "wp2.example.com",
        "version": 4.0,
        "lang": "ja",
        "db": {
          "name": "wp2",
          "user": "wordpress2",
          "pass": "wordpress2"
        }
      }
    ]
  },
  "run_list": [
    "recipe[wordpress]"
  ]
}

In this example, WordPress 3.6 is installed in /var/www/wp1.example.com and WordPress 4.0 is installed in /var/www/wp2.example.com.

Contributing

  1. Fork the repository on Github
  2. Create a named feature branch (like add_component_x)
  3. Write your change
  4. Write tests for your change (if applicable)
  5. Run the tests, ensuring they all pass
  6. Submit a Pull Request using Github

License and Authors

Authors: vohedge

License: GPLv2

About

Just another wordpress cookbook for chef. This cookbook supports multiple WordPress install.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages