wordpress-folder-prepared

Example:

# Setup wordpress project.
- wordpress-folder-prepared:
    wordpress_installs:
    - name: my_site
      dbname: my_site_db
      dbuser: wordpress
      dbpass: wordpress_password
      dbhost: localhost
      path: /var/www/wordpress
      url: http://dev.frkl.io
      title: My Site
      admin_name: admin
      admin_email: hello@frkl.io
      admin_password: password123
      plugins:
      - name: updraftplus
        activate: true
      themes:
      - name: libra
        activate: true

Description

This uses the oefenweb.wordpress Ansible role to prepare a folder structure for multiple wordpress sites. For more information, check out the role documentation.

First, it makes sure the wp-cli application is installed, then it downloads the 'Wordpress' application and puts it into the 'path' of each one of the 'wordpress_install' items. Then it configures (creates admin user, etc.) every one of those items (if not configured yet), and installs their themes and plugins.

It also (optionally) sets up cron jobs and other options.

Resources

Variables

Name Type Default Description

wordpress_installs

list ordereddict()

A dict describing all required wordpress installs.

wp_cli_install_dir

string --

The install directory for wp-cli.

Examples

Example 1

Setup wordpress project.

Code
- wordpress-folder-prepared:
    wordpress_installs:
    - name: my_site
      dbname: my_site_db
      dbuser: wordpress
      dbpass: wordpress_password
      dbhost: localhost
      path: /var/www/wordpress
      url: http://dev.frkl.io
      title: My Site
      admin_name: admin
      admin_email: hello@frkl.io
      admin_password: password123
      plugins:
      - name: updraftplus
        activate: true
      themes:
      - name: libra
        activate: true

Command-line

frecklecute wordpress-folder-prepared --help

Usage: frecklecute wordpress-folder-prepared [OPTIONS]

  This uses the [oefenweb.wordpress Ansible
  role](https://github.com/Oefenweb/ansible-wordpress) to prepare a folder
  structure for multiple wordpress sites. For more information, check out
  the role documentation.

  First, it makes sure the [wp-cli](https://github.com/wp-cli/wp-cli)
  application is installed, then it downloads the 'Wordpress' application
  and puts it into the 'path' of each one of the 'wordpress_install' items.
  Then it configures (creates admin user, etc.) every one of those items (if
  not configured yet), and installs their themes and plugins.

  It also (optionally) sets up cron jobs and other options.

Options:
  --wordpress-installs WORDPRESS_INSTALLS
                                  A dict describing all required wordpress
                                  installs.
  --wp-cli-install-dir PATH       The install directory for wp-cli.
  --help                          Show this message and exit.