From ee41647ce92a0cc66c4cce5d4b58fff0c422b29f Mon Sep 17 00:00:00 2001 From: Mike Raab Date: Fri, 18 May 2018 13:00:58 -0500 Subject: [PATCH] K8s deployment YAML Karthik, can you create a YAML like the above to deploy your container on a K8s cluster as a NodePool service? --- deployment.yml | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 deployment.yml diff --git a/deployment.yml b/deployment.yml new file mode 100644 index 0000000..5c18562 --- /dev/null +++ b/deployment.yml @@ -0,0 +1,35 @@ +apiVersion: apps/v1 +kind: Deployment +metadata: + name: helloworld +spec: + selector: + matchLabels: + app: helloworld + replicas: 1 + template: + metadata: + labels: + app: helloworld + spec: + containers: + - name: helloworld + image: karthequian/helloworld:latest + ports: + - containerPort: 80 +--- +apiVersion: v1 +kind: Service +metadata: + name: helloworld +spec: + type: NodePort + selector: + app: helloworld + ports: + - name: client + protocol: TCP + port: 80 + nodePort: 32080 + selector: + app: helloworld