Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/GalleyBytes/terraform-operator
A Kubernetes CRD to handle terraform operations
https://github.com/GalleyBytes/terraform-operator
controller docker galleybytes helm-chart kubernetes kubernetes-crd operator terraform terraform-operator
Last synced: about 1 month ago
JSON representation
A Kubernetes CRD to handle terraform operations
- Host: GitHub
- URL: https://github.com/GalleyBytes/terraform-operator
- Owner: GalleyBytes
- License: apache-2.0
- Created: 2020-09-03T07:01:23.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2024-07-18T00:34:20.000Z (5 months ago)
- Last Synced: 2024-10-29T09:55:24.090Z (about 1 month ago)
- Topics: controller, docker, galleybytes, helm-chart, kubernetes, kubernetes-crd, operator, terraform, terraform-operator
- Language: Go
- Homepage: http://tf.galleybytes.com
- Size: 7.38 MB
- Stars: 365
- Watchers: 12
- Forks: 47
- Open Issues: 25
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-tf - terraform-operator - A Kubernetes CRD to handle Terraform operations. (Tools / Community providers)
README
# Terraform Operator
> A Kubernetes CRD and Controller to handle Terraform operations by generating k8s pods catered to perform Terraform workflows
## What is terraform-operator?
This project is:
- A way to run Terraform in Kubernetes by defining Terraform deployments as Kubernetes manifests
- A controller that configures and starts [Terraform Workflows](http://tf.galleybytes.com/docs/architecture/workflow/) when it sees changes to the Kubernetes manifest
- Workflow runner pods that execute Terraform plan/apply and other user-defined scriptsThis project is not:
- An HCL to YAML converter or vice versa
- A Terraform Module or Registry## Installation
The preferred method is to use helm. See [Install using Helm](http://tf.galleybytes.com/docs/getting-started/installation/#install-using-helm) on the docs.
Another simple method is to install the resources under `deploy` & `deploy/crds`
```bash
git clone https://github.com/galleybytes/terraform-operator.git
cd terraform-operator
kubectl apply -f deploy/bundles/v0.17.1/v0.17.1.yaml
```See [more installation options](http://tf.galleybytes.com/docs/getting-started/installation/).
## Docs
Visit [http://tf.galleybytes.com](http://tf.galleybytes.com) to read the docs.
## Related Projects and Tools
Here are some other projects that enhance the experience of Terraform Operator.
### Debug With `tfo` CLI
Terraform is great, but every now and then, a module takes a turn for the worse and the workflow fails. When this happens, a terraform workflow will need to be "debugged."
Fortunately, the `tfo` cli (https://github.com/isaaguilar/terraform-operator-cli) can be used to start a debug pod which is connected directly to the same terraform session the workflow runs. It does so by reading the TFO resource and generates a pod with the same environment vars, ConfigMaps, Secrets, and ServiceAccount as a regular workflow pod. Then it drops the user in a shell directly in the main module.
```bash
tfo debug my-tfo-resource --namespace default
```The user should be ready to rock-n-roll and show off their mad debugging skills.
```bash
Connecting to my-tfo-resource-ca6ajn94-v2-debug-qmjd5.....Try running 'terraform init'
/home/tfo-runner/generations/2/main$
```Happy debugging!
## Join the Community
Currently, I'm experimenting with a Discord channel. It may be tough when taking into account juggling a full time job and full time parenting, but I'll see what comes of it. Join the channel https://discord.gg/J5vRmT2PWg