Skip to content

Commit 86c41fa

Browse files
committed
feat(flux): add decryption and postBuild configs
1 parent 6400112 commit 86c41fa

5 files changed

Lines changed: 44 additions & 3 deletions

File tree

kubernetes/components/flux-instance/flux-ks.yaml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,16 @@ spec:
1515
kind: GitRepository
1616
name: iac
1717
namespace: flux-system
18+
decryption:
19+
provider: sops
20+
secretRef:
21+
name: sops-age
22+
postBuild:
23+
substituteFrom:
24+
- kind: ConfigMap
25+
name: cluster-config
26+
- kind: Secret
27+
name: cluster-secrets
1828
wait: true
1929
interval: 30m
2030
retryInterval: 1m
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
apiVersion: v1
2+
kind: Secret
3+
metadata:
4+
name: flux-token
5+
namespace: flux-system
6+
type: Opaque
7+
data:
8+
token: ENC[AES256_GCM,data:AZ4LQjSXhtRAsAq+WR9gZXvWzCqao02oTj+6tUrk7u/fPOoOeguwkn6zTzk=,iv:DKctIYcmwFUF/qO2gyG85rtWQ2VouNIuxc1nHVfX2rk=,tag:3lXuPH4lc8f6JcLQemL0AQ==,type:str]
9+
sops:
10+
age:
11+
- recipient: age18z6wevr8ze5azvq7nfty3l29s7887l8n5mefr64avhlthtr4uvnqw90nfs
12+
enc: |
13+
-----BEGIN AGE ENCRYPTED FILE-----
14+
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBobDFWT1VacVViTngzcWUw
15+
UVlUb2RjdkxENDl2VTcrYlU2Ym1jbHgyTGc0CkxMZVMzMk9KWnl1M3lnMnZsMXo2
16+
a0dQakpjM2diVHAzN0tWZWVYTTJpNTgKLS0tIFQ4UEJPclRxbEZKQ0M4THhlQUww
17+
UHAwazV4Q0tqYlVzZzR3S2JXY0RlcWcKqiiw5nST35SVoMgk0/5jsILKENJ9xvyY
18+
cL4aYBOGo5sgWcG3LBb4/GsIKkcSnBnbusp0W7LrpXFsvNm+P+x2Xg==
19+
-----END AGE ENCRYPTED FILE-----
20+
lastmodified: "2025-10-01T07:02:02Z"
21+
mac: ENC[AES256_GCM,data:da0s8CTx/17J5sFW3OEokDDZYI0GZerTdvcxfxUYKllXtOHsqBQOY/LpKY5YjbMTeqBJPdLuu1+A/xKUV8Wz0/9K/Sb/W7up3MPQY2psGx1U5m8nCxKM//YZkCWXigEXgJpDGAgdaz9myCRwP6qYzPA/Ggyk0e7/7QJ16i2WE5U=,iv:UBB295j/CS0RWeooiudcnA4VCJ4lVPOTLX4QkY87Gyk=,tag:OCGsDwp+vyWFcSEo0ewqlA==,type:str]
22+
encrypted_regex: ^(data|stringData)$
23+
version: 3.10.2

kubernetes/components/flux-instance/receiver.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ spec:
99
type: github
1010
events: ["ping", "push"]
1111
secretRef:
12-
name: FLUX_TOKEN
12+
name: flux-token
1313
resources:
1414
- apiVersion: source.toolkit.fluxcd.io/v1
1515
kind: GitRepository
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
apiVersion: kustomize.config.k8s.io/v1beta1
2+
kind: Kustomization
3+
resources:
4+
- helmrelease.yaml
5+
- tofu/
Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
1+
---
2+
# yaml-language-server: $schema=https://json.schemastore.org/kustomization
13
apiVersion: kustomize.config.k8s.io/v1beta1
24
kind: Kustomization
35
resources:
4-
- helmrelease.yaml
5-
- tofu/
6+
- metrics-server/
7+
- flux-operator/
8+
- flux-instance/

0 commit comments

Comments
 (0)