Added cluster variables for flux substitutions
This commit is contained in:
@@ -32,3 +32,4 @@ patches:
|
||||
patchesControlPlane:
|
||||
- !patch allow-control-plane-workloads
|
||||
- !patch sops
|
||||
- !patch cluster-variables
|
||||
|
||||
@@ -4,6 +4,7 @@ installDisk: /dev/vda
|
||||
autoInstall: true
|
||||
cluster:
|
||||
name: testing
|
||||
production: false
|
||||
controlPlaneIp: 192.168.1.100
|
||||
secretsFile: !realpath _secrets.yaml
|
||||
sopsKeyFile: !realpath _age.agekey
|
||||
|
||||
@@ -3,6 +3,7 @@ gateway: 10.0.0.1
|
||||
installDisk: /dev/sda
|
||||
cluster:
|
||||
name: titan
|
||||
production: true
|
||||
controlPlaneIp: 10.0.2.1
|
||||
secretsFile: !realpath _secrets.yaml
|
||||
sopsKeyFile: !realpath _age.agekey
|
||||
|
||||
16
patches/cluster-variables.yaml
Normal file
16
patches/cluster-variables.yaml
Normal file
@@ -0,0 +1,16 @@
|
||||
cluster:
|
||||
inlineManifests:
|
||||
- name: cluster-variables
|
||||
contents: |
|
||||
apiVersion: v1
|
||||
kind: Namespace
|
||||
metadata:
|
||||
name: flux-system
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
name: cluster-variables
|
||||
namespace: flux-system
|
||||
data:
|
||||
cluster_env: {%- if node.cluster.production %} production {%- else %} staging {%- endif %}
|
||||
Reference in New Issue
Block a user