-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fluxtomize with multiple levels of subdirectories (#298)
Allow fluxtomize to process nested subdirectories Relates to: #295
- Loading branch information
Showing
13 changed files
with
123 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
--- | ||
apiVersion: kustomize.toolkit.fluxcd.io/v1 | ||
kind: Kustomization | ||
metadata: | ||
name: apps | ||
namespace: flux-system | ||
spec: | ||
interval: 10m0s | ||
path: ./tests/testdata/cluster7/flux/apps | ||
prune: true | ||
dependsOn: | ||
- name: charts | ||
sourceRef: | ||
kind: GitRepository | ||
name: flux-system |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
--- | ||
apiVersion: kustomize.toolkit.fluxcd.io/v1 | ||
kind: Kustomization | ||
metadata: | ||
name: charts | ||
namespace: flux-system | ||
spec: | ||
interval: 10m0s | ||
path: ./tests/testdata/cluster7/flux/charts | ||
prune: true | ||
sourceRef: | ||
kind: GitRepository | ||
name: flux-system |
27 changes: 27 additions & 0 deletions
27
tests/testdata/cluster7/clusters/home/flux-system/gotk-sync.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
# This manifest was generated by flux. DO NOT EDIT. | ||
--- | ||
apiVersion: source.toolkit.fluxcd.io/v1 | ||
kind: GitRepository | ||
metadata: | ||
name: flux-system | ||
namespace: flux-system | ||
spec: | ||
interval: 1m0s | ||
ref: | ||
branch: master | ||
secretRef: | ||
name: flux-system | ||
url: ssh://[email protected]/allenporter/flux-local | ||
--- | ||
apiVersion: kustomize.toolkit.fluxcd.io/v1 | ||
kind: Kustomization | ||
metadata: | ||
name: flux-system | ||
namespace: flux-system | ||
spec: | ||
interval: 10m0s | ||
path: ./tests/testdata/cluster7/clusters/home | ||
prune: true | ||
sourceRef: | ||
kind: GitRepository | ||
name: flux-system |
5 changes: 5 additions & 0 deletions
5
tests/testdata/cluster7/clusters/home/flux-system/kustomization.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
apiVersion: kustomize.config.k8s.io/v1beta1 | ||
kind: Kustomization | ||
resources: | ||
- gotk-sync.yaml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
apiVersion: v1 | ||
kind: Namespace | ||
metadata: | ||
name: database | ||
labels: | ||
kustomize.toolkit.fluxcd.io/prune: disabled |
16 changes: 16 additions & 0 deletions
16
tests/testdata/cluster7/flux/apps/database/postgresql/helm-release.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
--- | ||
apiVersion: helm.toolkit.fluxcd.io/v2beta1 | ||
kind: HelmRelease | ||
metadata: | ||
name: postgresql | ||
namespace: database | ||
spec: | ||
interval: 15m | ||
chart: | ||
spec: | ||
chart: postgresql | ||
version: 12.7.1 | ||
sourceRef: | ||
kind: HelmRepository | ||
name: bitnami-charts | ||
namespace: flux-system |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
--- | ||
apiVersion: source.toolkit.fluxcd.io/v1beta2 | ||
kind: HelmRepository | ||
metadata: | ||
name: bitnami-charts | ||
namespace: flux-system | ||
spec: | ||
type: oci | ||
interval: 5m | ||
url: oci://registry-1.docker.io/bitnamicharts |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
args: | ||
- get | ||
- cluster | ||
- --path | ||
- tests/testdata/cluster7/ | ||
stdout: | | ||
NAME PATH KUSTOMIZATIONS | ||
flux-system ./tests/testdata/cluster7/clusters/home 3 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
args: | ||
- get | ||
- hr | ||
- -A | ||
- --path | ||
- tests/testdata/cluster7 | ||
stdout: | | ||
NAMESPACE NAME REVISION CHART SOURCE | ||
database postgresql 12.7.1 database-postgresql bitnami-charts |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
args: | ||
- get | ||
- ks | ||
- --path | ||
- tests/testdata/cluster7 | ||
stdout: | | ||
NAME PATH | ||
apps tests/testdata/cluster7/flux/apps | ||
charts tests/testdata/cluster7/flux/charts | ||
flux-system tests/testdata/cluster7/clusters/home |