mirror of
https://github.com/outbackdingo/homelab-v.git
synced 2026-08-25 07:10:14 +00:00
feat(tofu): better way of supplying apiServer arguments
This commit is contained in:
@@ -36,7 +36,7 @@ data "talos_machine_configuration" "this" {
|
||||
templatefile("${path.module}/machine-config/control-plane.yaml.tftpl", {
|
||||
cilium_values = file("${path.root}/${var.cilium.values_path}")
|
||||
cilium_install = file("${path.root}/${var.cilium.install_manifest_path}")
|
||||
base_domain = var.cluster.base_domain
|
||||
api_server = var.cluster.api_server
|
||||
}) : ""
|
||||
]
|
||||
}
|
||||
|
||||
@@ -83,4 +83,4 @@ spec:
|
||||
volumes:
|
||||
- name: values
|
||||
configMap:
|
||||
name: cilium-values
|
||||
name: cilium-values
|
||||
|
||||
@@ -7,13 +7,7 @@ machine:
|
||||
cluster:
|
||||
allowSchedulingOnControlPlanes: true
|
||||
apiServer:
|
||||
extraArgs:
|
||||
oidc-issuer-url: https://authelia.${base_domain}
|
||||
oidc-client-id: kubectl
|
||||
oidc-username-claim: preferred_username
|
||||
oidc-username-prefix: 'authelia:'
|
||||
oidc-groups-claim: groups
|
||||
oidc-groups-prefix: 'authelia:'
|
||||
${indent(4, api_server)}
|
||||
network:
|
||||
cni:
|
||||
name: none
|
||||
|
||||
@@ -23,7 +23,7 @@ variable "cluster" {
|
||||
talos_machine_config_version = optional(string)
|
||||
proxmox_cluster = string
|
||||
kubernetes_version = string
|
||||
base_domain = string
|
||||
api_server = optional(string)
|
||||
})
|
||||
}
|
||||
|
||||
@@ -48,6 +48,6 @@ variable "cilium" {
|
||||
description = "Cilium configuration"
|
||||
type = object({
|
||||
install_manifest_path = string
|
||||
values_path = string
|
||||
values_path = string
|
||||
})
|
||||
}
|
||||
|
||||
@@ -13,7 +13,15 @@ talos_cluster_config = {
|
||||
talos_machine_config_version = "v1.9.2"
|
||||
proxmox_cluster = "homelab"
|
||||
kubernetes_version = "1.32.0" # renovate: github-releases=kubernetes/kubernetes
|
||||
base_domain = "stonegarden.dev"
|
||||
api_server = <<-EOT
|
||||
extraArgs:
|
||||
oidc-issuer-url: "https://authelia.stonegarden.dev"
|
||||
oidc-client-id: "kubectl"
|
||||
oidc-username-claim: "preferred_username"
|
||||
oidc-username-prefix: "authelia:"
|
||||
oidc-groups-claim: "groups"
|
||||
oidc-groups-prefix: "authelia:"
|
||||
EOT
|
||||
}
|
||||
|
||||
cilium_config = {
|
||||
|
||||
@@ -39,7 +39,7 @@ variable "talos_cluster_config" {
|
||||
talos_machine_config_version = optional(string)
|
||||
proxmox_cluster = string
|
||||
kubernetes_version = string
|
||||
base_domain = string
|
||||
api_server = optional(string)
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user