Drupal Requirements
Tokaido is ready to support the most common Drupal configurations. Before using Tokaido for your project, it’s a good idea to make sure it’s compatible.
Tokaido works with Drupal projects running:
- Drupal 7 or Drupal 8
- PHP 7.1
- Your Drupal site must be in a Git repository
It is highly recommended that your project also includes the following best practices:
- You should use PHP Composer to install and manage your Drupal site and modules
- Your Drupal site should be located in a sub-directory off your Git root, such as
/web
or/docroot
.
While building Tokaido, we made some assumptions about how most people develop their Drupal sites. If you can’t satisfy these requirements, but would still like to use Tokaido, please get in touch. We want to hear from you so that we know that there is demand for other use cases, and we hope we can ask you to help us test support for these new configurations.
Installing on MacOS
Before installing Tokaido on Mac, please ensure you have the following pre-requisites installed:
- Docker for Mac
- Homebrew package manager
With Docker and Homebrew installed, getting Tokaido on MacOS is easy! Simply open a Terminal window (we recommend iTerm 2) and run the following commands to install with Homebrew.
brew tap ironstar-io/tap
brew install tokaido
That’s all you need to do to install Tokaido on Mac! Go and check out the Using Tokaido section now to create your Tokaido environment
Installing on Linux
Tokaido works great on Linux, but requires a little bit of preliminary set up work. We don’t currently ship Tokaido with any Linux package managers, but installing and updating the binary is really easy.
System Requirements
- Debian, Ubuntu, Archlinux, Redhat, and CentOS are all compatible
- You will need Docker and Docker Compose installed
- Unison File Synchronizer
- ocaml
- fsmonitor , which can be installed with
pip install fsmonitor
Note that fsmonitor
and unison-fsmonitor
are both required but are installed separately.
Installing unison-fsmonitor Manually
Unison is a file-sync program that Tokaido uses to sync files between your local host and the Tokaido environment running in Docker. Unison offers better performance and cross-platform support over other file-sync solutions found in other Druapl environment managers.
The unison-fsmonitor
utility is an add-on for Unison that monitors your disk and initiates a sync between Tokaido and your local system. Sadly, this requires a little bit of manual installation for Linux users.
Determine your Unison version
Depending on your Linux distribution, you might be running Unison 2.48.4 or Unison 2.51.2. You can determine your version easily by running unison -version
Installing unison-fsmonitor for Unison 2.48.4
Unison 2.48.4 is common on Debian/Ubuntu and RedHat/CentOS/Fedora.
To install unison-fsmonitor
for Unison 2.48.4, you can run the following commands. These download the Unison source code and compile the unison-fsmonitor
addon.
UNISON_VERSION=2.48.4
curl -L https://github.com/bcpierce00/unison/archive/${UNISON_VERSION}.tar.gz | tar zxv -C /tmp
cd /tmp/unison-${UNISON_VERSION}
sed -i -e 's/GLIBC_SUPPORT_INOTIFY 0/GLIBC_SUPPORT_INOTIFY 1/' src/fsmonitor/linux/inotify_stubs.c
make UISTYLE=text NATIVE=true STATIC=true
sudo cp src/unison src/unison-fsmonitor /usr/local/bin
sudo chmod +x /usr/local/bin/unison-fsmonitor
Installing unison-fsmonitor for Unison 2.51.2
Unison 2.51.2 is common on Archlinux and related distributions.
To install unison-fsmonitor
for Unison 2.48.4, you can run the following commands. These download the Unison source code and compile the unison-fsmonitor
addon.
UNISON_VERSION=v2.51.2
curl -L https://github.com/bcpierce00/unison/archive/${UNISON_VERSION}.tar.gz | tar zxv -C /tmp
cd /tmp/unison-${UNISON_VERSION}
sed -i -e 's/GLIBC_SUPPORT_INOTIFY 0/GLIBC_SUPPORT_INOTIFY 1/' src/fsmonitor/linux/inotify_stubs.c
make UISTYLE=text NATIVE=true STATIC=true
sudo cp src/unison src/unison-fsmonitor /usr/local/bin
sudo chmod +x /usr/local/bin/unison-fsmonitor
Installing Tokaido on Linux
Once you’ve satisfied the requirements, you can simply download Tokaido from Github.
wget -q --show-progress https://github.com/ironstar-io/tokaido/releases/download/edge/tok-linux-amd64
chmod +x tok-linux-amd64
sudo mv tok-linux-amd64 /usr/local/bin/tok
That’s it! You’re ready to start using Tokaido
Installing on Windows
Tokaido can be installed on Windows using the binary packages. First, though, need to satisfy the system requirements:
- Windows 10 Pro or Enterprise. Docker can not run on Windows 10 Home.
- PowerShell v5+.
- Docker CE for Windows
- Chocolatey package manager
To install Tokaido on Windows, you can download a binary release and save it on your local system.
Notes about Windows
- The build for Windows is currently in beta and should be considered experimental
- The shell that Tokaido runs in, (PowerShell etc.), must started with
Run as Administrator
- Unison v2.48.4 (stable) is installed for you by Tokaido, alternative versions of Unison will not work with Tokaido on Windows