Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ A powerful and user-friendly Command Line Interface (CLI) for [Kubero](https://g
- [Linode](#linode)
- [DigitalOcean](#digitalocean)
- [Google GKE](#google-gke)
- [OVH](#ovh)
- [Development Guide](#development-guide)
- [Contributing](#contributing)
- [License](#license)
Expand Down Expand Up @@ -147,6 +148,7 @@ Kubero CLI currently supports the following cloud providers:
- **Linode**
- **DigitalOcean**
- **Google GKE**
- **OVH** (Managed Kubernetes)
- **Kind** (local clusters)

### Coming Soon
Expand Down Expand Up @@ -255,6 +257,12 @@ export DIGITALOCEAN_ACCESS_TOKEN=your_access_token
export GOOGLE_API_KEY=your_api_key
```

### OVH

No credentials required. Create your Managed Kubernetes cluster in the
[OVH control panel](https://www.ovh.com/manager/#/public-cloud/), download
the kubeconfig file and provide its path during `kubero install`.

---

## Development Guide
Expand Down
9 changes: 7 additions & 2 deletions cmd/kuberoCli/install.go
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ var monitoringInstalled bool
var ingressControllerVersion = "v1.10.0" // https://github.com/kubernetes/ingress-nginx/tags -> controller-v1.5.1

// var clusterTypeSelection = "[scaleway,linode,gke,digitalocean,kind]"
var clusterTypeList = []string{"kind", "linode", "scaleway", "gke", "digitalocean"}
var clusterTypeList = []string{"kind", "linode", "scaleway", "gke", "digitalocean", "ovh"}

func init() {
installCmd.Flags().StringVarP(&argComponent, "component", "c", "", "install component (kubernetes,olm,ingress,metrics,certManager,kubero-operator,monitoring,kubero-ui)")
Expand Down Expand Up @@ -172,6 +172,8 @@ func installKubernetes() {
installGKE()
case "digitalocean":
installDigitalOcean()
case "ovh":
installOVH()
case "kind":
installKind()
default:
Expand Down Expand Up @@ -373,6 +375,8 @@ func installIngress() {
prefill = "scw"
case "digitalocean":
prefill = "do"
case "ovh":
prefill = "cloud"
}

ingressProviderList := []string{"kind", "aws", "baremetal", "cloud", "do", "exoscale", "scw"}
Expand Down Expand Up @@ -705,7 +709,8 @@ func installKuberoUi() {
if clusterType == "linode" ||
clusterType == "digitalocean" ||
clusterType == "scaleway" ||
clusterType == "gke" {
clusterType == "gke" ||
clusterType == "ovh" {
kuberoUIConfig.Spec.Ingress.ClassName = "nginx"
}

Expand Down
33 changes: 33 additions & 0 deletions cmd/kuberoCli/install_ovh.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
package kuberoCli

import (
"log"
"os"

"github.com/i582/cfmt/cmd/cfmt"
)

// ponytail: OVH provides the kubeconfig for its managed clusters directly.
// No OVH API integration (request signing, app keys) needed — create the
// cluster in the OVH control panel, download the kubeconfig and merge it.
func installOVH() {

_, _ = cfmt.Println("{{ OVH Managed Kubernetes clusters are created via the OVH control panel:}}::gray")
_, _ = cfmt.Println("{{ https://www.ovh.com/manager/#/public-cloud/ -> Managed Kubernetes Service}}::gray")
_, _ = cfmt.Println("{{ Download the kubeconfig file of your cluster to continue.}}::gray")

kubeconfigPath := promptLine("Path to the OVH kubeconfig file", "", "kubeconfig.yml")

kubeconfig, err := os.ReadFile(kubeconfigPath)
if err != nil {
_, _ = cfmt.Println("{{✗ Failed to read kubeconfig file " + kubeconfigPath + "}}::red")
log.Fatal(err)
}

err = mergeKubeconfig(kubeconfig)
if err != nil {
_, _ = cfmt.Println("{{✗ Failed to merge kubeconfig}}::red")
log.Fatal(err)
}
_, _ = cfmt.Println("{{✓ Kubeconfig merged}}::lightGreen")
}