This project build an "HashiStack" demo on OCI. It is a 3-step workflow:
- BUILD: using Packer, Ansible and Bash scripts. The output is a Custom Image, ready to deploy Consul+Nomad nodes on Linux/arm64 using Ampere Altra CPU
- PROVISION: using Terraform Registry, Terraform Cloud with OCI. The output is an OCI Networking structure and security rules, together with 3 Computes Instances and a bastion host
- RUN: with Consul and Nomad on a 3-nodes cluster, with some example Nomad jobs and Consul content to come
Details about the provisioned infrastructure can be found in the "Provision" folder of this repo.
The whole architecure deployed by this project can be contained in the Oracle Cloud Always Free tier allocation, which comes with Compute, Storage, the cloud networking stuff and a hefty 10TB Outbound Data Transfer per month. So it should not cost you a single penny to try :-D
First, you will need to build your custom image
> cd build
> packer build .
Once your Custom image is built, let's provision it
> cd ../provision
> terraform init
> terraform plan
> terraform apply
Once you are connected to your cluster nodes through the bastion, you can verify that both Consul and Nomad clusters are up & runnning.
> cd ../run
> nomad server members
> consul members