AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |
Back to Blog
Kubectl create deployment command line12/28/2022 ![]() ![]() ![]() - image tag, usually defines a version or simply use latest.nodejs-hello-world imagePullPolicy: Always ports: - name: web containerPort: 3000 imagePullSecrets: - name: regcredīesides a familiar look of service and deployment definition, there are a couple of items that are needed to be highlighted: Kubernetes manifest file would consist out of the following objects:ĪpiVersion: v1 kind: Service metadata: name: health-check-service namespace: health-check spec: type: NodePort ports: - port: 3000 selector: app: node-hello-world-app - apiVersion: apps/v1 kind: Deployment metadata: name: node-hello-world-deployment namespace: health-check labels: app: node-hello-world-app spec: replicas: 1 selector: matchLabels: app: node-hello-world-app template: metadata: labels: app: node-hello-world-app spec: containers: - name: node-hello-world-app-container image. We would create namespace manually via kubectl create command (for the reasons I explain later).įrom the application standpoint, we would consider a minimalistic "health check application" that replies with status: ok as an HTTP response. OverviewĪs a good practice, it's always best to deploy a different set of applications in separate namespaces. Make sure that the machine that is going to be used to perform the deployment (whether it's your local or most likely CI/CD environment) does have aws-cli installed and configured with proper access key id and secret access key so that it has access to pull an image. In this short article, I would like to share a sequence of steps that can be used to perform the deployment. Although there are a lot of instructions available, I haven't found a straightforward way of deploying a container to Kubernetes cluster that is hosted in a private ECR registry. ![]()
0 Comments
Read More
Leave a Reply. |