OVH Cloud Crossplane Provider

Ismail KABOUBI
Edixos
Published in
8 min readJan 10, 2024

Platform Engineering: Integrating Kubernetes with OVH Cloud through Crossplane Control Plane.

🌟Introduction

In the dynamic world of cloud computing and Kubernetes, collaborations that drive innovation are not just celebrated; they are milestones marking progress in technological advancement. Today, we are thrilled to announce a pivotal development at Edixos — a strategic partnership with OVHcloud, a leader in cloud services. This collaboration is not just a testament to our commitment in the realm of Kubernetes consulting but also a leap forward in the cloud-native landscape.

At Edixos, our journey has always been about pushing the boundaries of what’s possible in Kubernetes environments. Aligning with OVHcloud is a natural progression of our mission, as we both share a dedication to excellence in cloud solutions. This partnership is more than just a mutual alignment of goals; it’s a fusion of expertise and innovation, setting a new standard in the industry.

A significant hallmark of this collaboration is the introduction of the provider-ovh for Crossplane, especially as we celebrate the launch of its version 0.1.3 early this year. The provider-ovh is a shining example of how we at Edixos are not just participating in the Kubernetes ecosystem but actively contributing to its evolution. This addition to the Crossplane marketplace isn’t just a product; it’s a reflection of our expertise and passion for technological advancement, promising a more intuitive and self-service management of cloud resources.

As we embark on this exciting new chapter with OVHcloud, we are proud to not only contribute to the Kubernetes community but also to empower it. The provider-ovh is our invitation to the world: to explore, to integrate, and to advance with us in this ever-evolving cloud-native journey.

Join us as we delve deeper into the technicalities of installing and leveraging the provider-ovh in a kind cluster, and how it seamlessly integrates OVHcloud services with Kubernetes, paving the way for a more efficient and scalable cloud management experience.

🌐 Background on Edixos and OVHcloud

Edixos, a beacon in the realm of Kubernetes consulting, has established itself as an expert in navigating the complexities of cloud-native technologies. Specializing in Kubernetes, Edixos has been instrumental in simplifying and optimizing cloud infrastructure for a diverse range of clients. With a deep understanding of cloud dynamics and a commitment to delivering tailored solutions, Edixos has consistently demonstrated its ability to transform challenges into opportunities for innovation and growth in the cloud computing domain.

On the other side of this partnership stands OVHcloud, a global cloud service provider known for its comprehensive suite of cloud solutions, including the renowned SecNumCloud service. OVHcloud has carved out a significant niche in the industry with its robust, scalable, and secure cloud offerings, catering to a wide array of business needs. Known for its dedication to data sovereignty and security, OVHcloud’s commitment to providing reliable and efficient cloud services has made it a preferred choice for businesses seeking a secure digital transformation journey. This collaboration between Edixos and OVHcloud, is set to redefine the standards of cloud computing and Kubernetes consulting, further enhancing the capabilities and reach of cloud-native technologies.

🔍 Exploring Crossplane and provider-ovh

Crossplane is an open-source tool that changes how we handle different environments in cloud computing. It’s like an extension to the Kubernetes API, making it easier to set up, configure, and manage complex workloads and systems. The best part? Crossplane lets developers manage infrastructure using the same tools and methods they already use for applications. This makes everything more streamlined and efficient, bridging the gap between application development and infrastructure management. For more details, check out the official documentation.

Provider-ovh

provider-ovh is all about making it easier to use OVHcloud services with Kubernetes clusters. It’s a big step forward in making cloud management simpler and more self-service.

You can find provider-ovh on GitHub. What it does is let users manage OVHcloud resources, like computer servers, network setups, and storage options, right through Crossplane. This means managing cloud resources becomes more flexible and scalable.

🛠️ Technical Deep Dive: Implementing Crossplane and Provider-ovh in Kubernetes

Setting up Crossplane in a Kind Cluster

Our first step is to establish a Kubernetes cluster, and for this, we’re using Kind, which conveniently sets up a Kubernetes cluster in Docker. Here’s how we do it:

🦋 ➸  kind create cluster --image kindest/node:v1.27.2 --wait 5m --name provider-ovh
Creating cluster "provider-ovh" ...
✓ Ensuring node image (kindest/node:v1.27.2) 🖼
✓ Preparing nodes 📦
✓ Writing configuration 📜
✓ Starting control-plane 🕹️
✓ Installing CNI 🔌
✓ Installing StorageClass 💾
✓ Waiting ≤ 5m0s for control-plane = Ready ⏳
• Ready after 14s 💚
Set kubectl context to "kind-provider-ovh"
You can now use your cluster with:

kubectl cluster-info --context kind-provider-ovh

Have a nice day! 👋

This command initializes the “provider-ovh” cluster. Kind ensures the node image is prepared, configures the nodes, and sets up the necessary Kubernetes components. Once the control-plane is ready and the cluster is set up, you’ll get a confirmation message.

Once we have the cluster up and running, we need to install crossplane. For that we will use helm to deploy it.

Next, we install Crossplane, the Kubernetes add-on for managing cloud infrastructure, using Helm:

🦋 ➸  helm repo add crossplane-stable https://charts.crossplane.io/stable
🦋 ➸ helm repo update
🦋 ➸ helm install crossplane --namespace crossplane-system --create-namespace crossplane-stable/crossplane
NAME: crossplane
LAST DEPLOYED: Wed Jan 10 21:11:42 2024
NAMESPACE: crossplane-system
STATUS: deployed
REVISION: 1
TEST SUITE: None
NOTES:
Release: crossplane

Chart Name: crossplane
Chart Description: Crossplane is an open source Kubernetes add-on that enables platform teams to assemble infrastructure from multiple vendors, and expose higher level self-service APIs for application teams to consume.
Chart Version: 1.14.5
Chart Application Version: 1.14.5

Kube Version: v1.27.2

This command deploys Crossplane into the crossplane-system namespace.

Verify that the Crossplane pods are running with:

🦋 ➸  kubectl get pods -n crossplane-system
NAME READY STATUS RESTARTS AGE
crossplane-76df4b8d9d-r8ggt 1/1 Running 0 83s
crossplane-rbac-manager-75f4c66d5d-8twrq 1/1 Running 0 83s

Install the provider-ovh

There are two methods to install the provider-ovh:

  1. Using the up command line:
🦋 ➸  up ctp provider install edixos/provider-ovh:v0.1.3

using kubectl command line.

🦋 ➸  kubectl apply -f - <<EOF
apiVersion: pkg.crossplane.io/v1
kind: Provider
metadata:
name: provider-ovh
spec:
package: xpkg.upbound.io/edixos/provider-ovh:v0.1.3
runtimeConfigRef:
name: provider-ovh
---
apiVersion: pkg.crossplane.io/v1beta1
kind: DeploymentRuntimeConfig
metadata:
name: provider-ovh
spec:
deploymentTemplate:
spec:
selector: {}
template:
spec:
containers:
- name: package-runtime
args:
- --debug
EOF

To confirm that the provider is successfully installed:

🦋 ➸  kubectl get pods -n crossplane-system    -w
NAME READY STATUS RESTARTS AGE
crossplane-76df4b8d9d-r8ggt 1/1 Running 0 19m
crossplane-rbac-manager-75f4c66d5d-8twrq 1/1 Running 0 19m
provider-ovh-bfde1d30d1aa-694b694858-qtsh9 1/1 Running 0 12s

Look for the provider-ovh pod along with the Crossplane pods to ensure they are all running.
Now, with the provider-ovh installed, you can begin creating and managing resources in your Kubernetes cluster.

🚀 Deploying a Managed Kubernetes Cluster Using Provider-ovh

In this section, we’ll explore how to deploy a managed Kubernetes cluster using the managed resources available through provider-ovh. The following YAML configurations define the necessary resources for this deployment:

Creating a Cluster

This resource definition creates a Kubernetes cluster named “hello-edixos” in the DE1 region with version 1.28.

apiVersion: kube.ovh.edixos.io/v1alpha1
kind: Cluster
metadata:
name: hello-edixos
spec:
providerConfigRef:
name: default
forProvider:
name: "hello-edixos"
region: DE1
serviceName: 980cbcf06e6a4e6e8a91a7d125b26bba
version: "1.28"

Setting Up IP Restriction

This configuration applies an IP restriction to the cluster, allowing access only from the specified IP address (1.1.1.1/32 in this example).

apiVersion: kube.ovh.edixos.io/v1alpha1
kind: IpRestriction
metadata:
name: hello-edixos
spec:
providerConfigRef:
name: default
forProvider:
serviceName: 980cbcf06e6a4e6e8a91a7d125b26bba
ips:
- 1.1.1.1/32
kubeIdRef:
name: hello-edixos

Creating a Node Pool

This defines a node pool for the cluster, specifying the desired, maximum, and minimum number of nodes, along with other settings like the node flavor.

apiVersion: kube.ovh.edixos.io/v1alpha1
kind: NodePool
metadata:
name: hello-edixos
spec:
providerConfigRef:
name: default
forProvider:
serviceName: 980cbcf06e6a4e6e8a91a7d125b26bba
name: hello-crossplane
flavorName: b2-7
desiredNodes: 1
maxNodes: 1
minNodes: 1
monthlyBilled: false
kubeIdRef:
name: hello-edixos

Verifying the Deployment

After applying the configurations, use commands like kubectl get to verify the status of the created resources, such as the cluster, IP restriction, and node pool.

🦋 ➸  k get clusters.kube.ovh.edixos.io
NAME READY SYNCED EXTERNAL-NAME AGE
hello-edixos True True 38229788-9b4f-4375-ae81-5bc78f1f8c3e 19m

🦋 ➸ k get nodepools.kube.ovh.edixos.io
NAME READY SYNCED EXTERNAL-NAME AGE
hello-edixos True True 65d85525-0e95-4004-b767-624defd09216 22m

🦋 ➸ k get iprestrictions.kube.ovh.edixos.io
NAME READY SYNCED EXTERNAL-NAME AGE
hello-edixos True True 38229788-9b4f-4375-ae81-5bc78f1f8c3e 22m

The provider will populate the status.atProvider as any crossplane provider, you can check the observed resource details on that field.

🦋 ➸  k get clusters.kube.ovh.edixos.io hello-edixos -o jsonpath='{.status.atProvider}' | jq
{
"controlPlaneIsUpToDate": true,
"customizationApiserver": [
{
"admissionplugins": [
{
"enabled": [
"AlwaysPullImages",
"NodeRestriction"
]
}
]
}
],
"id": "38229788-9b4f-4375-ae81-5bc78f1f8c3e",
"isUpToDate": true,
"kubeProxyMode": "iptables",
"name": "hello-edixos",
"nodesUrl": "rjc60c.nodes.c1.de1.k8s.ovh.net",
"privateNetworkId": "",
"region": "DE1",
"serviceName": "980cbcf06e6a4e6e8a91a7d125b26bba",
"status": "READY",
"updatePolicy": "ALWAYS_UPDATE",
"url": "rjc60c.c1.de1.k8s.ovh.net",
"version": "1.28"
}

You can also checkout the configuration from ovh manager console:

🎉Conclusion

It’s important to highlight that provider-ovh is still under active development. This ongoing development is a testament to the commitment of Edixos in constantly enhancing and evolving its offerings to meet the ever-changing demands of the cloud computing landscape. As a young and dynamic company, Edixos is at the forefront of exploring new possibilities and pushing the boundaries of what can be achieved in cloud infrastructure management.

The provider-ovh’s current capabilities, from creating clusters and node pools to implementing IP restrictions, only scratch the surface of its potential. As development continues, we can expect to see more features, improvements in usability, and even more seamless integration with OVHcloud services. This continuous improvement cycle is pivotal in ensuring that provider-ovh not only keeps pace with the advancements in cloud technology but also leads the way in innovation.

For Kubernetes practitioners, cloud architects, and those invested in the cloud-native ecosystem, the evolution of provider-ovh is an exciting journey to be a part of. Edixos invites the community to engage with, contribute to, and grow with provider-ovh. Together, we can shape the future of cloud-native technologies and redefine the possibilities of Kubernetes management.

In summary, provider-ovh represents more than just a tool; it embodies a vision for a more efficient, flexible, and intuitive approach to cloud management. It’s a step towards a future where Kubernetes and cloud infrastructure operate in even greater harmony, unlocking new levels of efficiency and capability for organizations worldwide.

Wrapping Up

🎉 That’s a wrap on our deep dive into Kubernetes management with provider-ovh! Thank you so much for joining me on this journey. I hope you found it enlightening and are as excited about these developments as I am.

🚀 As we reach the end of this post, I’d love to extend my gratitude for your time and attention. If there are any aspects of this blog that sparked your curiosity or if you have thoughts to share, I’m always open for a chat or discussion:

Farewell Until Next Time!

✨ Once again, thank you for reading. Stay tuned for more insights and explorations in future posts. Let’s keep the learning and sharing spirit alive!

🔗 Remember, every step forward in our tech journey is a step towards greater knowledge and collaboration.

Stay curious, stay connected!

--

--