Skip to content

asastech/finstrap

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

58 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Kubernetes Bootstrapper: An Extendable Framework to Set Up Production Grade Clusters

Introduction

"Production-grade" is a loaded term. What constitutes production readiness will vary according to your use case. While a Kubernetes cluster is production-ready the moment it is ready to serve traffic, there is a commonly agreed set of minimum requirements, as shown in the infographic below.

k8s-prod

Kubernetes Finstrap

The k8s-finstrap project is a customizable and extendable framework that aims to solve this problem by leveraging

  • Terraform: Compose a production ready infrastructure on Kubernetes
  • Vault: Kubernetes clusters with the power of Vault and dynamic secrets
  • Argo CD: Application configuration management and delivery using GitOps

This project integrates popular battle-tested open-source software and solutions that provide a production-grade out-of-box Kubernetes experience.

 Overview

├── LICENSE
├── README.md 
├── argocd # Argo CD configurations (optional)
├── finstrap # cluster finstrap using Argo CD
├── docs # documents and assets
├── infrastructure # infrastructure automation using Terraform
  

Using Terraform to Provision Infrastructure on Kubernetes

Follow the below steps to get started:

optional deployment Kubernetes single-node

 ./install-script.sh
  1. Clone this repo and change the directory to infrastructure

  2. Initialize Terraform backend:

    export KUBE_CONFIG_PATH=~/.kube/config
    
    cd infrastructure
    
    terraform init
  3. Copy and rename the finstrap.tfvars.backup file to finstrap.tfvars:

    cp finstrap.tfvars.backup finstrap.tfvars
  4. Open the finstrap.tfvars file and adjust settings according to your needs using a text editor of your choice (preferably with HCL lint support).

  5. Use terraform plan to inspect infra changes before applying:

    terraform plan -var-file=finstrap.tfvars -out tf-finstrap.out
  6. If you're happy with the changes, issue terraform apply:

 Tear down the finstrap Cluster

Had fun trying out the k8s-finstrap? Time to say goodbye!

# Run
cd infrastructure
terraform destroy --var-file=finstrap.tfvars --auto-approve
# Bye Bye!

Next steps »