fix ip_not_available error
This commit is contained in:
parent
4aabee0dad
commit
1165389fc3
@ -58,7 +58,7 @@ resource "hcloud_server" "agents" {
|
||||
token = random_password.k3s_token.result
|
||||
kubelet-arg = "cloud-provider=external"
|
||||
flannel-iface = "eth1"
|
||||
node-ip = cidrhost(hcloud_network_subnet.k3s.ip_range, 257 + count.index)
|
||||
node-ip = cidrhost(hcloud_network_subnet.k3s.ip_range, 513 + count.index)
|
||||
node-label = var.automatically_upgrade_k3s ? ["k3s-upgrade=true"] : []
|
||||
})
|
||||
destination = "/tmp/config.yaml"
|
||||
@ -100,7 +100,7 @@ resource "hcloud_server" "agents" {
|
||||
|
||||
network {
|
||||
network_id = hcloud_network.k3s.id
|
||||
ip = cidrhost(hcloud_network_subnet.k3s.ip_range, 257 + count.index)
|
||||
ip = cidrhost(hcloud_network_subnet.k3s.ip_range, 513 + count.index)
|
||||
}
|
||||
|
||||
depends_on = [
|
||||
|
@ -1,5 +1,5 @@
|
||||
locals {
|
||||
first_control_plane_network_ip = cidrhost(hcloud_network_subnet.k3s.ip_range, 2)
|
||||
first_control_plane_network_ip = cidrhost(hcloud_network_subnet.k3s.ip_range, 257)
|
||||
hcloud_image_name = "ubuntu-20.04"
|
||||
|
||||
ssh_public_key = trimspace(file(var.public_key))
|
||||
|
@ -60,9 +60,9 @@ resource "hcloud_server" "control_planes" {
|
||||
disable = "servicelb, local-storage"
|
||||
flannel-iface = "eth1"
|
||||
kubelet-arg = "cloud-provider=external"
|
||||
node-ip = cidrhost(hcloud_network_subnet.k3s.ip_range, 3 + count.index)
|
||||
advertise-address = cidrhost(hcloud_network_subnet.k3s.ip_range, 3 + count.index)
|
||||
tls-san = cidrhost(hcloud_network_subnet.k3s.ip_range, 3 + count.index)
|
||||
node-ip = cidrhost(hcloud_network_subnet.k3s.ip_range, 258 + count.index)
|
||||
advertise-address = cidrhost(hcloud_network_subnet.k3s.ip_range, 258 + count.index)
|
||||
tls-san = cidrhost(hcloud_network_subnet.k3s.ip_range, 258 + count.index)
|
||||
node-taint = var.allow_scheduling_on_control_plane ? [] : ["node-role.kubernetes.io/master:NoSchedule"]
|
||||
node-label = var.automatically_upgrade_k3s ? ["k3s-upgrade=true"] : []
|
||||
})
|
||||
@ -104,7 +104,7 @@ resource "hcloud_server" "control_planes" {
|
||||
|
||||
network {
|
||||
network_id = hcloud_network.k3s.id
|
||||
ip = cidrhost(hcloud_network_subnet.k3s.ip_range, 3 + count.index)
|
||||
ip = cidrhost(hcloud_network_subnet.k3s.ip_range, 258 + count.index)
|
||||
}
|
||||
|
||||
depends_on = [
|
||||
|
@ -10,9 +10,9 @@ spec:
|
||||
type: LoadBalancer
|
||||
annotations:
|
||||
"load-balancer.hetzner.cloud/name": "traefik"
|
||||
# make hetzners load-balancer connect to our nodes via our private k3s-net.
|
||||
# make hetzners load-balancer connect to our nodes via our private k3s
|
||||
"load-balancer.hetzner.cloud/use-private-ip": "true"
|
||||
# keep hetzner-ccm from exposing our private ingress ip, which in general isn't routeable from the public internet.
|
||||
# keep hetzner-ccm from exposing our private ingress ip, which in general isn't routeable from the public internet
|
||||
"load-balancer.hetzner.cloud/disable-private-ingress": "true"
|
||||
# disable ipv6 by default, because external-dns doesn't support AAAA for hcloud yet https://github.com/kubernetes-sigs/external-dns/issues/2044
|
||||
"load-balancer.hetzner.cloud/ipv6-disabled": "${lb_disable_ipv6}"
|
||||
|
Loading…
Reference in New Issue
Block a user