@ -75,12 +75,12 @@ cluster e.g. `staging-cluster` and `production-cluster`:
```sh
├── staging-cluster # < - path = staging-cluster
│ └── gitops -system # < - namespace dir generated by bootstrap
│ └── gotk -system # < - namespace dir generated by bootstrap
│ ├── toolkit-components.yaml
│ ├── toolkit-kustomization.yaml
│ └── toolkit-source.yaml
└── production-cluster # < - path = production-cluster
└── gitops -system
└── gotk -system
```
!!! hint "Change the default branch"
@ -185,7 +185,7 @@ cd my-repository
Create a directory inside the repository:
```sh
mkdir -p ./my-cluster/gitops -system
mkdir -p ./my-cluster/gotk -system
```
Generate the toolkit manifests with:
@ -193,7 +193,7 @@ Generate the toolkit manifests with:
```sh
gotk install --version=latest \
--arch=amd64 \ # on ARM64/AARCH64 clusters use --arch=arm64
--export > ./my-cluster/gitops -system/toolkit-components.yaml
--export > ./my-cluster/gotk -system/toolkit-components.yaml
```
If your cluster must pull images from a private container registry, first you should pull
@ -205,12 +205,12 @@ docker tag ghcr.io/fluxcd/source-controller:v0.0.14 registry.internal/fluxcd/sou
docker push registry.internal/fluxcd/source-controller:v0.0.14
```
Create the pull secret in the `g itops -system` namespace:
Create the pull secret in the `g otk -system` namespace:
```sh
kubectl create ns gitops -system
kubectl create ns gotk -system
kubectl -n gitops -system create secret generic regcred \
kubectl -n gotk -system create secret generic regcred \
--from-file=.dockerconfigjson=/.docker/config.json \
--type=kubernetes.io/dockerconfigjson
```
@ -221,7 +221,7 @@ Set your registry domain, and the pull secret when generating the manifests:
gotk install --version=latest \
--registry=registry.internal/fluxcd \
--image-pull-secret=regcred \
--export > ./my-cluster/gitops -system/toolkit-components.yaml
--export > ./my-cluster/gotk -system/toolkit-components.yaml
```
Commit and push the manifest to the master branch:
@ -233,7 +233,7 @@ git add -A && git commit -m "add toolkit manifests" && git push
Apply the manifests on your cluster:
```sh
kubectl apply -f ./my-cluster/gitops -system/toolkit-components.yaml
kubectl apply -f ./my-cluster/gotk -system/toolkit-components.yaml
```
Verify that the toolkit controllers have started:
@ -245,7 +245,7 @@ gotk check
Create a `GitRepository` object on your cluster by specifying the SSH address of your repo:
```sh
gotk create source git gitops -system \
gotk create source git gotk -system \
--url= ssh://< host > /< org > /my-repository \
--ssh-key-algorithm=ecdsa \
--ssh-ecdsa-curve=p521 \
@ -259,7 +259,7 @@ If you don't specify the SSH algorithm, then gotk will generate an RSA 2048 bits
If your Git server supports basic auth, you can set the URL to HTTPS and specify the credentials with:
```sh
gotk create source git gitops -system \
gotk create source git gotk -system \
--url=https://< host > /< org > /my-repository \
--username=my-username \
--password=my-password \
@ -270,8 +270,8 @@ gotk create source git gitops-system \
Create a `Kustomization` object on your cluster:
```sh
gotk create kustomization gitops -system \
--source=gitops -system \
gotk create kustomization gotk -system \
--source=gotk -system \
--path="./my-cluster" \
--prune=true \
--interval=10m
@ -280,11 +280,11 @@ gotk create kustomization gitops-system \
Export both objects, commit and push the manifests to Git:
```sh
gotk export source git gitops -system \
> ./my-cluster/gitops -system/toolkit-source.yaml
gotk export source git gotk -system \
> ./my-cluster/gotk -system/toolkit-source.yaml
gotk export kustomization gitops -system \
> ./my-cluster/gitops -system/toolkit-kustomization.yaml
gotk export kustomization gotk -system \
> ./my-cluster/gotk -system/toolkit-kustomization.yaml
git add -A & & git commit -m "add toolkit reconciliation" & & git push
```
@ -293,7 +293,7 @@ To upgrade the toolkit to a newer version, run the install command and commit th
```sh
gotk install --version=latest \
--export > ./my-cluster/gitops -system/toolkit-components.yaml
--export > ./my-cluster/gotk -system/toolkit-components.yaml
git add -A & & git commit -m "update toolkit" & & git push
```
@ -347,7 +347,7 @@ gotk create source helm stable \
gotk create helmrelease sealed-secrets \
--interval=1h \
--release-name=sealed-secrets \
--target-namespace=gitops -system \
--target-namespace=gotk -system \
--source=HelmRepository/stable \
--chart=sealed-secrets \
--chart-version="1.10.x"
@ -356,7 +356,7 @@ gotk create helmrelease sealed-secrets \
## Monitoring with Prometheus and Grafana
The GitOps Toolkit comes with an optional monitoring stack.
You can install the stack in the `g itops -system` namespace with:
You can install the stack in the `g otk -system` namespace with:
```yaml
kustomize build github.com/fluxcd/toolkit/manifests/monitoring?ref=master | kubectl apply -f-
@ -377,7 +377,7 @@ If you wish to use your own Prometheus and Grafana instances, then you can impor
!!! hint
Note that the toolkit controllers expose the `/metrics` endpoint on port `8080` .
When using Prometheus Operator you should create `PodMonitor` objects to configure scraping.
When Prometheus is running outside of the `g itops -system` namespace, you have to create a network policy
When Prometheus is running outside of the `g otk -system` namespace, you have to create a network policy
that allows traffic on port `8080` from the namespace where Prometheus is deployed.
## Uninstall