Deploying with Ansible

2 min

While Ansible is not officially supported to deploy Garage, several community members have published Ansible roles. We list them and compare them below.

Comparison of Ansible roles

Featureansible-role-garagegarage-docker-ansible-deployeddster2309 ansible-role-garage
RuntimeSystemdDockerSystemd
Target OSAny LinuxAny LinuxAny Linux
Architectureamd64, arm64, i686amd64, arm64arm64, arm, 386, amd64
Additional softwareNoneTraefikNgnix and Keepalived (optional)
Automatic node connection
Layout management
Manage buckets & keys✅ (basic)
Allow custom Garage config
Facilitate Garage upgrades
Multiple instances on one host

zorun/ansible-role-garage

Source code, Ansible galaxy

This role is voluntarily simple: it relies on the official Garage static binaries and only requires Systemd. As such, it should work on any Linux-based OS.

To make things more flexible, the user has to provide a Garage configuration template. This allows to customize Garage configuration in any way.

Some more features might be added, such as a way to automatically connect nodes to each other or to define a layout.

moan0s/garage-docker-ansible-deploy

Source code, Blog post

This role is based on the Docker image for Garage, and comes with "batteries included": it will additionally install Docker and Traefik. In addition, it is "opinionated" in the sense that it expects a particular deployment structure (one instance per disk, one gateway per host, structured DNS names, etc).

As a result, this role makes it easier to start with Garage on Ansible, but is less flexible.

eddster2309/ansible-role-garage

Source code, Ansible galaxy

This role is a opinionated but customisable role using the official Garage static binaries and only requires Systemd. As such it should work on any Linux based host. It includes all the nesscary configuration to automatically setup a clustered Garage deployment. Most Garage configuration options are exposed through Ansible variables so while you can't provide a custom config you can get very close. It can optionally installed a HA nginx deployment with Keepalived.

Navigation