Files
homelab/ansible/playbooks/templates/install-config.yaml.j2

34 lines
1.3 KiB
Django/Jinja

apiVersion: v1
baseDomain: {{ hostvars[groups[cluster_group][0]].base_domain }}
compute:
- name: worker
hyperthreading: Enabled
replicas: {{ hostvars[groups[cluster_group][0]].worker_node_count }}
controlPlane:
hyperthreading: Enabled
name: master
replicas: {{ hostvars[groups[cluster_group][0]].master_node_count }}
metadata:
name: {{ hostvars[groups[cluster_group][0]].cluster_name }}
networking:
clusterNetwork:
- cidr: {{ hostvars[groups[cluster_group][0]].cluster_network }}
hostPrefix: {{ hostvars[groups[cluster_group][0]].cluster_network_host_prefix }}
machineNetwork:
- cidr: {{ hostvars[groups[cluster_group][0]].machine_network }}
networkType: OVNKubernetes
serviceNetwork:
- {{ hostvars[groups[cluster_group][0]].service_network }}
platform:
{% if hostvars[groups[cluster_group][0]].platform_type == 'none' %}
{{ hostvars[groups['hub_cluster'][0]].platform_type }}: {}
{% endif %}
{% if hostvars[groups[cluster_group][0]].platform_type == 'baremetal' %}
{{ hostvars[groups[cluster_group][0]].platform_type }}:
apiVIP: {{ hostvars[groups[cluster_group][0]].api_address }}
ingressVIP: {{ hostvars[groups[cluster_group][0]].app_address }}
{% endif %}
fips: false
pullSecret: '{{ vault_pull_secret }}'
sshKey: '{{ vault_ssh_key }}'