Getting Started
Prerequisites
To install this operator, you need the following:
kubectlkustomize(Optional)- A Kubernetes cluster with a recent enough version to support Custom Resource Definitions. The operator was initially built on
v1.22.5+k3s1and being developed onv1.25.4+k3s1.
Installation methods
Declarative installation (recommended)
Find the latest tag for cloudflare-operator.
Create a
kustomization.yamlin your repository:yamlapiVersion: kustomize.config.k8s.io/v1beta1 kind: Kustomization namespace: cloudflare-operator-system resources: # ensure you update the ref to the latest version - https://github.com/geo-mena/cloudflare-operator.git/config/default?ref=v0.13.1Deploy the application:
bash# either approach will work kubectl apply -k . kustomize build . | kubectl apply -f -
If you need to customize the operator, you can do so with kustomize.
Imperative installation
For a one-off installation, you can use any of the following methods.
Install a specific tag
In general, one should pick a specific tag. You can find the latest tag here.
bash
kubectl apply -k 'https://github.com/geo-mena/cloudflare-operator.git//config/default?ref=v0.13.1'Install the latest version
To install the latest version without checking tags:
bash
kubectl apply -k 'https://github.com/geo-mena/cloudflare-operator.git/config/default?ref=main'
kubectl apply -k 'https://github.com/geo-mena/cloudflare-operator/config/default'Next steps
Now that the operator is installed, we can make it useful:
- Deploy a secret with your API token
- Create a Tunnel/ClusterTunnel resource
- Configure routing for your tunnel:
Additional info
- Check the Configuration section to understand configurable parameters.
- Check the Migrations section for upgrade guides.