Created
May 2, 2020 11:47
-
-
Save Pablo-Merino/3fab1cfdc220bf9e36aa871c76d04d5d to your computer and use it in GitHub Desktop.
K8s Problems
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apiVersion: apps/v1 | |
kind: Deployment | |
metadata: | |
name: hello-deployment | |
namespace: default | |
spec: | |
replicas: 1 | |
selector: | |
matchLabels: | |
app: hello-deployment | |
template: | |
metadata: | |
labels: | |
app: hello-deployment | |
spec: | |
containers: | |
- name: kuard | |
image: gcr.io/kuar-demo/kuard-amd64:1 | |
ports: | |
- containerPort: 8080 | |
--- | |
kind: Service | |
apiVersion: v1 | |
metadata: | |
name: hello-svc | |
labels: | |
app: hello-deployment | |
spec: | |
ports: | |
- name: http | |
protocol: TCP | |
port: 80 | |
targetPort: 8080 | |
selector: | |
app: hello-deployment | |
type: LoadBalancer | |
externalTrafficPolicy: Cluster |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
apiVersion: extensions/v1beta1 | |
kind: Ingress | |
metadata: | |
name: hello-app-ingress | |
annotations: | |
kubernetes.io/ingress.class: "nginx" | |
cert-manager.io/cluster-issuer: "letsencrypt-staging" | |
acme.cert-manager.io/http01-edit-in-place: "true" | |
spec: | |
tls: | |
- hosts: | |
- tls.svc.k8s.pablo.host | |
secretName: "hello-app-staging-tls" | |
rules: | |
- host: tls.svc.k8s.pablo.host | |
http: | |
paths: | |
- path: / | |
backend: | |
serviceName: hello-svc | |
servicePort: 80 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment