I am trying to deploy my app to Kubernetes running in Google Container Engine.
The app can be found at: https://github.com/Industrial/docker-znc.
The Dockerfile is built into an image on Google Container Registry.
I have deployed the app in Kubernetes via the + button. I don't have the YAML for this.
I have inserted a Secret in Kubernetes for the PEM file required by the app.
- How do I get the YAML for the Deployment, Service and Pod created by Kubernetes by filling in the form?
- How do I get the Secret into my Pod for usage?
Syntax for downloading yaml's from kubernetes
kubectl get [resource type] -n [namespace] [resource Name] -o yaml > [New file name]
Create yaml file from running pod:
Create replicaset yaml file from running pod:
Create deployement yaml file from running pod:
If you need to view and edit the file use:
kubectl edit service servicename
for the 2nd question regarding the secret, this is from the k8s documentation. see https://kubernetes.io/docs/concepts/configuration/secret/#using-secrets for more info.
I have used this and it works fine.