Welcome to the k8s-demo
repository! This repository contains a variety of Kubernetes samples that demonstrate how to use different types of resources such as ConfigMaps, Services, Deployments, and Secrets. Each example is designed to provide practical insights and best practices for deploying applications on Kubernetes.
To use these examples, you will need a Kubernetes cluster. You can set one up using Minikube or use any existing Kubernetes environment you have access to.
- A Kubernetes cluster
- kubectl installed and configured to connect to your cluster
This repository is organized as follows:
- ConfigMaps - Examples on how to configure applications using ConfigMaps.
- Services - Demonstrations of various types of services for exposing your applications.
- Deployments - Deployment configurations that showcase different deployment strategies and use cases.
- Secrets - How to securely inject sensitive data into your applications. Examples Below are brief descriptions of what you will find in each directory:
simple-configmap.yaml
- Basic example of how to create a ConfigMap.
simple-service.yaml
- Example of setting up a simple service.
rolling-update-deployment.yaml
- Deployment that demonstrates a rolling update. Secretssimple-secret.yaml
- Example of how to create and use a Secret.
kubectl apply -f [filename]
Replace [filename] with the path to the YAML file you want to apply.