Installation

This page describes how to install Metacontroller, either to develop your own controllers or just to run third-party controllers that depend on it.

Docker images

Images are hosted in two places:

Feel free to use whatever suits your need, they identical. Note - currently in helm charts the dockerhub one's are used.

Prerequisites

  • Kubernetes v1.17+ (because of maintainability, e2e test suite might not cover all releases)
  • You should have kubectl available and configured to talk to the desired cluster.

Grant yourself cluster-admin (GKE only)

Due to a known issue in GKE, you'll need to first grant yourself cluster-admin privileges before you can install the necessary RBAC manifests.

kubectl create clusterrolebinding <user>-cluster-admin-binding --clusterrole=cluster-admin --user=<user>@<domain>

Replace <user> and <domain> above based on the account you use to authenticate to GKE.

Install Metacontroller using Kustomize

# Apply all set of production resources defined in kustomization.yaml in `production` directory .
kubectl apply -k https://github.com/metacontroller/metacontroller/manifests/production

If you prefer to build and host your own images, please see the build instructions in the contributor guide.

If your kubectl version does does not support -k flag, please install resources mentioned in manifests/production/kustomization.yaml one by one manually with kubectl apply -f {{filename}} command.

Install Metacontroller using Helm

Alternatively, metacontroller can be installed using an Helm chart.

Migrating from /GoogleCloudPlatform/metacontroller

As current version of metacontroller uses different name of the finalizer than GCP version (GCP - metacontroller.app, current version - metacontroller.io) thus after installing metacontroller you might need to clean up old finalizers, i.e. by running:

kubectl get <comma separated list of your resource types here> --no-headers --all-namespaces | awk '{print $2 " -n " $1}' | xargs -L1 -P 50 -r kubectl patch -p '{"metadata":{"finalizers": [null]}}' --type=merge