Created
September 11, 2019 12:13
-
-
Save gowatana/47f40f849543a4c9656f767271788e09 to your computer and use it in GitHub Desktop.
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: dep-game2048 | |
spec: | |
replicas: 1 | |
selector: | |
matchLabels: | |
run: game2048 | |
template: | |
metadata: | |
labels: | |
run: game2048 | |
spec: | |
containers: | |
- name: game2048 | |
image: gowatana/docker-2048 | |
ports: | |
- containerPort: 80 | |
protocol: TCP | |
restartPolicy: Always | |
--- | |
apiVersion: v1 | |
kind: Service | |
metadata: | |
name: svc-2048 | |
spec: | |
type: NodePort | |
ports: | |
- port: 80 | |
protocol: TCP | |
targetPort: 80 | |
nodePort: 30500 | |
selector: | |
run: game2048 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
nodePortを決め打ち。
実行方法はこれを参照
https://gist.github.com/gowatana/3a0179c41348e65c9769f71fadeace2d