Skip to content

Minio cluster automated install and setup with Terraform and Ansible

License

Notifications You must be signed in to change notification settings

adamkoro/minio-terraform-ansible

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

minio-terraform-ansible

Create Minio cluster easly with Terraform and Ansible

Original documentation

Requirements

  • Terraform
  • Ansible

How to use

  • Clone this repository.

Install

Terraform

  • Create a file called terraform.tfvars and fill it with your data:
cd terraform
cp terraform.tfvars.example terraform.tfvars
  • Run terraform init to initialize terraform.
terraform init
  • Run terraform plan to plan the infrastructure.
terraform plan
  • Run terraform apply to create the infrastructure.
terraform apply

Ansible

  • Run ansible-playbook to install Minio, Keepalived and Haproxy or Nginx on the servers.
Cluster playbook
cd ansible/cluster
cp inventory-example.yaml inventory.yaml

Edit that yaml file with your data

  • Run ansible-playbook to install Minio and Nginx on the servers.
ansible-playbook -i inventory.yaml playbooks/install.yml

Destroy

Terraform

  • Run terraform destroy to destroy the infrastructure.
cd terraform
terraform destroy

Ansible

  • Run ansible-playbook to uninstall installed apps and configs from the servers.
cd ansible/cluster
ansible-playbook -i inventory.yaml playbooks/reset.yml