Compare commits
2 commits
ae604b2082
...
354b68b30a
| Author | SHA1 | Date | |
|---|---|---|---|
| 354b68b30a | |||
| 267e57d1fc |
2 changed files with 16 additions and 4 deletions
|
|
@ -3,7 +3,7 @@
|
||||||
# when one shows up. Requires clusters/homelab/flux-system to have write
|
# when one shows up. Requires clusters/homelab/flux-system to have write
|
||||||
# access to the Forgejo repo (flux bootstrap sets this up).
|
# access to the Forgejo repo (flux bootstrap sets this up).
|
||||||
|
|
||||||
apiVersion: image.toolkit.fluxcd.io/v1beta2
|
apiVersion: image.toolkit.fluxcd.io/v1
|
||||||
kind: ImageRepository
|
kind: ImageRepository
|
||||||
metadata:
|
metadata:
|
||||||
name: hello-app
|
name: hello-app
|
||||||
|
|
@ -15,7 +15,7 @@ spec:
|
||||||
# secretRef:
|
# secretRef:
|
||||||
# name: forgejo-registry
|
# name: forgejo-registry
|
||||||
---
|
---
|
||||||
apiVersion: image.toolkit.fluxcd.io/v1beta2
|
apiVersion: image.toolkit.fluxcd.io/v1
|
||||||
kind: ImagePolicy
|
kind: ImagePolicy
|
||||||
metadata:
|
metadata:
|
||||||
name: hello-app
|
name: hello-app
|
||||||
|
|
@ -30,7 +30,7 @@ spec:
|
||||||
pattern: '^main-[a-f0-9]+-(?P<ts>\d+)$'
|
pattern: '^main-[a-f0-9]+-(?P<ts>\d+)$'
|
||||||
extract: '$ts'
|
extract: '$ts'
|
||||||
---
|
---
|
||||||
apiVersion: image.toolkit.fluxcd.io/v1beta1
|
apiVersion: image.toolkit.fluxcd.io/v1
|
||||||
kind: ImageUpdateAutomation
|
kind: ImageUpdateAutomation
|
||||||
metadata:
|
metadata:
|
||||||
name: hello-app
|
name: hello-app
|
||||||
|
|
|
||||||
|
|
@ -38,6 +38,15 @@ from `docs/01-bootstrap.md` step 4, not SSH (Forgejo's git-SSH port turned
|
||||||
out not to be reliably reachable from either this desktop or the T630 —
|
out not to be reliably reachable from either this desktop or the T630 —
|
||||||
see the earlier troubleshooting in this project's history):
|
see the earlier troubleshooting in this project's history):
|
||||||
|
|
||||||
|
`flux bootstrap` only installs its four core controllers
|
||||||
|
(`source-controller`, `kustomize-controller`, `helm-controller`,
|
||||||
|
`notification-controller`) unless told otherwise. hello-app's image
|
||||||
|
automation (step 7 below — `ImageRepository`/`ImagePolicy`/
|
||||||
|
`ImageUpdateAutomation`) needs two more, `image-reflector-controller` and
|
||||||
|
`image-automation-controller`, which are opt-in via `--components-extra`;
|
||||||
|
without it, hello-app's `Kustomization` fails dry-run with "no matches for
|
||||||
|
kind ImageRepository" since the CRD was never installed.
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
flux check --pre --kubeconfig ~/.kube/config-manual
|
flux check --pre --kubeconfig ~/.kube/config-manual
|
||||||
|
|
||||||
|
|
@ -48,6 +57,7 @@ flux bootstrap git \
|
||||||
--username=codegit \
|
--username=codegit \
|
||||||
--password=<FLUX_WRITE_TOKEN> \
|
--password=<FLUX_WRITE_TOKEN> \
|
||||||
--token-auth \
|
--token-auth \
|
||||||
|
--components-extra=image-reflector-controller,image-automation-controller \
|
||||||
--kubeconfig ~/.kube/config-manual
|
--kubeconfig ~/.kube/config-manual
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
@ -89,7 +99,9 @@ kubectl -n flux-system get deployments
|
||||||
```
|
```
|
||||||
|
|
||||||
`source-controller`, `kustomize-controller`, `helm-controller`,
|
`source-controller`, `kustomize-controller`, `helm-controller`,
|
||||||
`notification-controller`. Alongside them, it registered the CRDs those
|
`notification-controller`, plus `image-reflector-controller` and
|
||||||
|
`image-automation-controller` from `--components-extra` above. Alongside
|
||||||
|
them, it registered the CRDs those
|
||||||
controllers understand:
|
controllers understand:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue