Skip to main content
Fly Kubernetes is in closed beta and not recommended for critical production usage. To report issues or provide feedback, email us at beta@fly.io.
Fly Kubernetes clusters are accessible over an organization’s private WireGuard network. To connect to a cluster, you need a WireGuard configuration. Follow the Private Network VPN instructions to set up a permanent WireGuard connection to your Fly.io IPv6 private network. To connect to your cluster, you need a kubeconfig file. These are generated when your cluster is created. They can also be retrieved using flyctl. First, we need our cluster name:
Then, we can use flyctl to save our kubeconfig to disk. It is automatically saved with the name kubeconfig in the current directory
With the kubeconfig file, you can connect to your cluster. To make life easier, you can move the kubeconfig file to the default location kubectl searches for it, $HOME/.kube, under the name config. Alternatively set the environment variable KUBECONFIG to the path to the kubeconfig file
Once set up, you can use kubectl: