Read Me

Project Bonsai Screenshot

Project Bonsai

Project Bonsai is a secure and modern WordPress stack.

The goal: To simplify the process of building a Roots WordPress site with a streamlined configuration with a corresponding tutorial videos.

Bonsai is a custom configuration of WordPress, Roots, Trellis, Bedrock, Sage, Bootstrap and other open source projects.

Tutorial

Trello board: Speed Run

For a video tutorial on creating a Bonsai project from scratch, go to the official website or our Youtube channel.

Quick Setup

We’re going to take a few minutes to setup all the requirements to ensure that deploying Project Bonsai goes smoothly:

Download Bonsai

Download project Bonsai from the official website or from the github repository.

Don’t forget to move Bonsai from your downloads folder into your ~/Sites directory.

OR

To download with the command line, run:
cd ~/sites and git clone https://github.com/jackalopeio/Bonsai.git

Requirements

Create SSH Keys

Install Requirements

Shell Script: If you’re going to run Bonsai/site/scripts/requirements.sh for installation, don’t forget to set permissions by running:
cd ~/sites/Bonsai/site/scripts && chmod -R 777 .

  • Install xcode dev tools: xcode-select --install
  • Update to PHP >=7.2
  • Homebrew: /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
  • Node: brew install nvm
  • Ansible: brew install ansible
  • Composer: brew install composer
  • Yarn: brew install yarn
  • Virtualbox: brew cask install --appdir="/Applications" virtualbox
  • Vagrant: brew cask install --appdir="/Applications" vagrant
  • Vagrant Manager: brew cask install --appdir="/Applications" vagrant-manager
  • Atom: brew cask install --appdir="/Applications" atom
  • iTerm2: brew cask install --appdir="/Applications" iterm2
  • Github Desktop App: brew cask install --appdir="/Applications" github-desktop

You can rename the current file by clicking the file name in the navigation bar or by clicking the Rename button in the file explorer.

First, Check

If you’re recreating a project, you may want to check these things just to be sure:

  • Remove unnecessary Virtualbox machines
  • Clear: ~/.ssh/known_hosts
  • Clear: ~/../../etc/hosts

Servers

By default, we use DigitalOcean base Ubuntu servers for Project Bonsai.

Nameservers:

First, you’ll want to make sure that your Domain Registrant points towards DigitalOcean.

  • ns1.digitalocean.com
  • ns2.digitalocean.com
  • ns3.digitalocean.com

Create Droplets:

Create two base Ubuntu DigitalOcean Droplets. Link them to your SSH key.

Setup DNS:

Configure etc/hosts:

Add IP and domains to etc/hosts, run: sudo vim ~/../../etc/hosts

111.11.111.111 subdomain.example.com
555.55.555.555 example.com www.example.com

Configure ~/.ssh/config:

Add IP and hostname to ~/.ssh/config, run: sudo vim ~/.ssh/config

Host bonsai-staging
        HostName 111.11.111.11
        Port 22
        User root
        IdentityFile ~/.ssh/id_rsa

Host bonsai-production
        HostName 555.55.555.555
        Port 22
        User root
        IdentityFile ~/.ssh/id_rsa

Test SSH Connection:

Make sure that your SSH connections are working by SSH’ing into the servers:

  • Staging, run: ssh root@subdomain.example.com
  • Production, run: ssh root@example.com

Configure Bonsai

Under construction, for the rest of the tutorial look at:

Trello board: Speed Run

Roots Trellis Docs: The Basics

For a video tutorial on creating a Bonsai project from scratch, go to the official website or our Youtube channel.

Leave a Reply

Your email address will not be published. Required fields are marked *

Devs

Start a free trial to get full access

Become Devs Pro Member
$5

Start a free trial to get full access

Become 3D Pro Member
$5

Join the Devs group to get full access

  • $0.00