git-clone-controller

by Riotkit

Helm chartv1.1.0-alpha5App v1.1-alpha5

Simple Pod provisioner using GIT as source. Just label your Pods to get an additional initContainer that will clone your repo before Pod will start up.

About this chart

GIT clone operator

Mutation webhook handler, injects initContainer with a properly configured git container that does a clone or checkout, taking care about permissions.

Use cases

Mounting static user-data in official images

With this approach you can still use official application images like Wordpress image without having to maintain your own images just to inject a theme, plugins or some other custom files.

Simple administrative jobs without CI system

Simply clone your scripts repository in your pod workspace, execute script and exit.

Git clone inside CI job

git-clone-controller checkout is a CLI command that could be a replacement of git clone and git checkout. It's advantage is that it is designed to be running automatic: When repository does not exists, it gets cloned, when exists, then updated with remote.

Setting up

Use helm to install git-clone-controller. For helm values please take a look at values reference.

helm repo add riotkit-org https://riotkit-org.github.io/helm-of-revolution/
helm install my-git-clone-controller riotkit-org/git-clone-controller                

Documentation

For more documentation please take a look at Github page

Deploy git-clone-controller with OpenTenant

Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has git-clone-controller on a Hetzner server. Change the host, add apps from the marketplace, then copy the generated files. Providers and prices are samples, and nothing here is sent anywhere.

  1. Pick a serverConnect Hetzner, OVHcloud or AWS. The builder starts on Hetzner, the cheapest sample rate.
  2. Place the chartgit-clone-controller is pinned at v1.1.0-alpha5 in opentenant.yaml. Drag more apps from the marketplace onto a rack.
  3. ApplySave opentenant.yaml and main.tf from the console, then run the commands below.
# opentenant.yaml, main.tf and dns.tf come from the builder below
opentenant validate opentenant.yaml
terraform init && terraform apply