Created
January 1, 2020 18:10
-
-
Save jcgregorio/6105f3a3b5f5e42e4cb349da719fa6c6 to your computer and use it in GitHub Desktop.
helloweb deployment + service + ingress
This file contains hidden or 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: helloweb | |
labels: | |
app: hello | |
spec: | |
selector: | |
matchLabels: | |
app: hello | |
template: | |
metadata: | |
labels: | |
app: hello | |
spec: | |
containers: | |
- name: hello-app | |
image: gcr.io/google-samples/hello-app:1.0 | |
ports: | |
- containerPort: 8080 | |
--- | |
apiVersion: v1 | |
kind: Service | |
metadata: | |
name: helloweb-backend | |
labels: | |
app: hello | |
spec: | |
type: NodePort | |
selector: | |
app: hello | |
ports: | |
- port: 8080 | |
targetPort: 8080 | |
--- | |
apiVersion: networking.k8s.io/v1beta1 | |
kind: Ingress | |
metadata: | |
name: helloweb | |
labels: | |
app: hello | |
spec: | |
backend: | |
serviceName: helloweb-backend | |
servicePort: 8080 | |
spec: | |
rules: | |
- http: | |
paths: | |
- backend: | |
serviceName: helloweb-backend | |
servicePort: 8080 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment