To create a kubeconfig file from a DigitalOcean cluster, log into the DigitalOcean dashboard and in the left hand menu select Manage then Kubernetes. Alternatively, go to Projects, select the project containing your cluster, then look in the Clusters panel. Select the cluster to import, then click the Kubeconfig option to download the kubeconfig file.