Install WordPress with composer

This website was deployed using a hand full of files and composer.

These files were pushed to the Buddy VCS and using its pipeline features those few files were uploaded to this server via SFTP.

Buddy then connected using SSH and executed the command:

compser install

This installed WordPress thanks a package from: John P. Bloch


Composer also installs some themes and plugins, this is a copy of my composer.json file at the time of writing this short post.

  "repositories": [
      "type": "composer",
      "url": ""
  "require": {
    "php": ">=5.4",
    "composer/installers": "1.*",
    "johnpbloch/wordpress": "^4.8",
  "extra": {
    "wordpress-install-dir": "wp",
    "installer-paths": {
      "content/mu-plugins/{$name}/": [
      "content/plugins/{$name}/": [
      "content/themes/{$name}/": [

This also defines the WordPress install folder as wp and the wp-content folder as content for my theme and plugins installed using wpackagist.

If you don’t include a theme such as twenty seventeen as I have here then your install will load blank.

If you are interested in doing this you will require a few files like an index.php to call wordpress and a wp-config.php for the config as well as defining an env-config.php file for the database connection.

You can find these in a repo I have created on github to show the files needed.

This was just a quick post for the first post on my blog for some content I will go more in depth with detail in future posts.