cluster-api-provider-hetzner
cluster-api-provider-hetzner copied to clipboard
HCloudMachineTemplate and ipv6 not working
/kind bug
What steps did you take and what happened: I was trying to deploy ipv6 only machines.
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1
kind: HCloudMachineTemplate
metadata:
name: name-md-0
spec:
template:
spec:
publicNetwork:
enableIPv4: false
enableIPv6: true
What did you expect to happen: I was expecting ipv6 only machines
Anything else you would like to add: nothing
Environment:
- cluster-api-provider-hetzner version: caph:v1.0.0
- Kubernetes version: 1.30.1
- OS (e.g. from
/etc/os-release):
We use the hcloud-go provider for this: https://github.com/syself/cluster-api-provider-hetzner/blob/c6cab3c53bc89782018698a8aec98575a52c3879/pkg/services/hcloud/server/server.go#L379
There is no more logic involved in CAPH to control this. Maybe you can explain a bit more what happens, so that the root cause of your problem is easier to find?
I use the setting you see above. The machines are created but also with a ipv4 interface. That's all. I had the impression this is sufficient to tell hetzner to create machines without ipv4. Or do I need to fulfill more requirements?
@apricote do you know?
This IPv4 is always enabled if the cluster does not use private networks, maybe thats the cause?
https://github.com/syself/cluster-api-provider-hetzner/blob/c6cab3c53bc89782018698a8aec98575a52c3879/pkg/services/hcloud/server/server.go#L463-L466