allenporter / flux-local

flux-local is a set of tools and libraries for managing a local flux gitops repository focused on validation steps to help improve quality of commits, PRs, and general local testing.
https://allenporter.github.io/flux-local/
Apache License 2.0
155 stars 22 forks source link

Exercise postBuild.substituteFrom in tests #624

Closed allenporter closed 7 months ago

allenporter commented 7 months ago

Issue #617

github-actions[bot] commented 7 months ago
--- tests/testdata/cluster/clusters/prod Kustomization: flux-system/flux-system Kustomization: flux-system/apps

+++ tests/testdata/cluster/clusters/prod Kustomization: flux-system/flux-system Kustomization: flux-system/apps

@@ -9,12 +9,15 @@

   namespace: flux-system
 spec:
   dependsOn:
   - name: infra-configs
   interval: 10m0s
   path: ./tests/testdata/cluster/apps/prod
+  postBuild:
+    substitute:
+      cluster_env: production
   prune: true
   sourceRef:
     kind: GitRepository
     name: flux-system
   timeout: 5m0s
   wait: true
github-actions[bot] commented 7 months ago
--- HelmRelease: podinfo/podinfo Ingress: podinfo/podinfo

+++ HelmRelease: podinfo/podinfo Ingress: podinfo/podinfo

@@ -6,13 +6,13 @@

   labels:
     app.kubernetes.io/name: podinfo
     app.kubernetes.io/managed-by: Helm
 spec:
   ingressClassName: nginx
   rules:
-  - host: podinfo.production
+  - host: podinfo.prod
     http:
       paths:
       - path: /
         pathType: ImplementationSpecific
         backend:
           service:
github-actions[bot] commented 7 months ago
--- HelmRelease: podinfo/podinfo Ingress: podinfo/podinfo

+++ HelmRelease: podinfo/podinfo Ingress: podinfo/podinfo

@@ -6,13 +6,13 @@

   labels:
     app.kubernetes.io/name: podinfo
     app.kubernetes.io/managed-by: Helm
 spec:
   ingressClassName: nginx
   rules:
-  - host: podinfo.production
+  - host: podinfo.prod
     http:
       paths:
       - path: /
         pathType: ImplementationSpecific
         backend:
           service:
github-actions[bot] commented 7 months ago
--- tests/testdata/cluster/clusters/prod Kustomization: flux-system/flux-system Kustomization: flux-system/apps

+++ tests/testdata/cluster/clusters/prod Kustomization: flux-system/flux-system Kustomization: flux-system/apps

@@ -9,12 +9,15 @@

   namespace: flux-system
 spec:
   dependsOn:
   - name: infra-configs
   interval: 10m0s
   path: ./tests/testdata/cluster/apps/prod
+  postBuild:
+    substitute:
+      cluster_env: production
   prune: true
   sourceRef:
     kind: GitRepository
     name: flux-system
   timeout: 5m0s
   wait: true