deployment.yaml⚓︎
Overview⚓︎
The 'deployment.yaml' file is a Kubernetes deployment configuration file used to define and manage the deployment of a specific application or service within a Kubernetes cluster. It specifies the desired state for the deployment, including the number of replicas, pod template, and other deployment-related settings.
Table of Contents⚓︎
Prerequisites⚓︎
No specific dependencies or prerequisites are mentioned in the file.
Usage⚓︎
To use the 'deployment.yaml' file in a project, you can apply it to a Kubernetes cluster using the 'kubectl apply' command. For example:
Methods⚓︎
The file contains the following key components and methods: - 'apiVersion', 'kind', and 'metadata' fields define the basic metadata for the deployment. - The 'spec' section specifies the desired state of the deployment, including the number of replicas, pod template, and other settings. - The 'template' section defines the pod template for the deployment, including metadata, labels, and the specification of containers. - The 'containers' section specifies the containers to be deployed, including their name, image, ports, probes, resources, and other settings.
Useful details⚓︎
- The file uses Helm template functions to dynamically include values from the project's configuration.
- It supports the configuration of image pull secrets, service account, security context, node selectors, affinity, and tolerations for the deployment.
- It also provides support for defining liveness and readiness probes for the deployed containers.