-
Notifications
You must be signed in to change notification settings - Fork 0
/
flux.cue
37 lines (33 loc) · 826 Bytes
/
flux.cue
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
package holos
import (
"path"
ks "kustomize.toolkit.fluxcd.io/kustomization/v1"
)
#ComponentConfig: {
Name: _
Namespace: _
OutputBaseDir: _
let ArtifactPath = path.Join([OutputBaseDir, "gitops", "\(Name).kustomization.gen.yaml"], path.Unix)
let ResourcesPath = path.Join([OutputBaseDir, "components", Name], path.Unix)
Artifacts: "\(Name)-kustomization": {
artifact: ArtifactPath
generators: [{
kind: "Resources"
output: artifact
resources: Kustomization: (Name): ks.#Kustomization & {
metadata: name: Name
metadata: namespace: "flux-system"
spec: {
targetNamespace: Namespace
interval: "10m"
path: ResourcesPath
prune: true
sourceRef: {
kind: "OCIRepository"
name: "default"
}
}
}
}]
}
}