What you will learn in this TP
- Create a local Kubernetes cluster
- Expose an application with a LoadBalancer
- Use a persistent volume
Introduction #
What you will learn in this section
- Create a local Kubernetes cluster
- Expose an application with a LoadBalancer
- Use a persistent volume
Context. Before ordering a Managed Kubernetes cluster, you validate your manifests and habits on a local cluster.
Prerequisites: Docker, the AWS CLI (for the S3 API), kubectl, k3d and Terraform 1.7 or later; everything is simulated locally, with no OVHcloud account · Estimated time: 45 min
An exposed, persistent and scaled application, ready for MKS.Hands-on #
Guided steps, with their solution.
1. Create the cluster
Why? k3d runs k3s in Docker; its built-in load balancer plays the role of the OVHcloud Load Balancer.
Create a cluster with one server and two agents, publishing port 8080.2. Deploy and expose
Why? On Managed Kubernetes, a LoadBalancer Service creates an OVHcloud Load Balancer with a public IP.
Deploy three nginx replicas, expose them and test.3. Add a persistent volume
Why? On OVHcloud, the csi-cinder storage class creates a Block Storage volume.
Create a 1 Gi PVC and a pod that writes to it, delete the pod then check the data persists.4. Scale and clean up
Why? On MKS, the node pool autoscaler adds nodes when pods no longer fit.
Scale to 6 replicas, observe distribution across nodes then delete the cluster.
Difficulty level : ●●●○○ (3/5)
My progress
Sign in to track your progress and take notes. Sign in
Recommended Articles
Le calcul sur OVHcloud : instances Public Cloud et Managed Kubernetes Service
Choisir et utiliser le calcul OVHcloud : gammes d'instances (General Purpose, CPU, RAM, GPU, Disc...
Exploiter OVHcloud : Terraform, supervision, sécurité, coûts et souveraineté
Exploiter OVHcloud en production : infrastructure as code avec les fournisseurs Terraform ovh et ...
Le stockage OVHcloud : Block Storage, Object Storage compatible S3 et Cold Archive
Stocker des données sur OVHcloud : volumes Block Storage (classique, haute performance), Object S...
Kubernetes : exposer ses applications (Services, Ingress et Gateway API)
Exposer des applications dans Kubernetes : Services ClusterIP/NodePort/LoadBalancer, Ingress, Ing...
CaaS état de l'art et bonnes pratiques
Le Container as a Service (CaaS) est un modèle de cloud computing qui permet aux entreprises de g...
Bonnes pratiques OVHcloud : organisation, sécurité, réseau, sauvegarde et coûts
Les bonnes pratiques pour exploiter le Public Cloud OVHcloud en production : projets par environn...
Terraform sur plusieurs clouds : AWS, Azure, Google Cloud, OVHcloud et Kubernetes
Utiliser Terraform avec les principaux fournisseurs : aws, azurerm, google, ovh et openstack, kub...
Comprendre OVHcloud : univers, régions, Public Cloud et outils
Découvrir OVHcloud, fournisseur de cloud européen : univers Bare Metal, Hosted Private Cloud, Pub...
Identités et accès sur OVHcloud : compte, IAM, utilisateurs OpenStack et clés
Sécuriser l'accès à OVHcloud : double authentification du compte, IAM OVHcloud (identités, politi...