Skip to content

Commit

Permalink
simplify example workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
cppforlife committed Jul 13, 2020
1 parent 2b736f1 commit 638f8ed
Show file tree
Hide file tree
Showing 4 changed files with 281 additions and 273 deletions.
1 change: 1 addition & 0 deletions examples/simple-app-example/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Based on https://github.com/k14s/k8s-simple-app-example/tree/develop/config-step-1-minimal
33 changes: 33 additions & 0 deletions examples/simple-app-example/config-1.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
---
apiVersion: v1
kind: Service
metadata:
namespace: default
name: simple-app
spec:
ports:
- port: 80
targetPort: 80
selector:
simple-app: ""
---
apiVersion: apps/v1
kind: Deployment
metadata:
namespace: default
name: simple-app
spec:
selector:
matchLabels:
simple-app: ""
template:
metadata:
labels:
simple-app: ""
spec:
containers:
- name: simple-app
image: docker.io/dkalinin/k8s-simple-app@sha256:4c8b96d4fffdfae29258d94a22ae4ad1fe36139d47288b8960d9958d1e63a9d0
env:
- name: HELLO_MSG
value: stranger
45 changes: 45 additions & 0 deletions examples/simple-app-example/config-2.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
---
apiVersion: v1
kind: Service
metadata:
namespace: default
name: simple-app-node
spec:
type: NodePort
ports:
- port: 80
targetPort: 80
nodePort: 31111
selector:
simple-app: ""
---
apiVersion: apps/v1
kind: Deployment
metadata:
namespace: default
name: simple-app
spec:
selector:
matchLabels:
simple-app: ""
template:
metadata:
labels:
simple-app: ""
spec:
containers:
- name: simple-app
image: docker.io/dkalinin/k8s-simple-app@sha256:4c8b96d4fffdfae29258d94a22ae4ad1fe36139d47288b8960d9958d1e63a9d0
env:
- name: HELLO_MSG
valueFrom:
configMapKeyRef:
name: simple-app
key: hello_msg
---
apiVersion: v1
kind: ConfigMap
metadata:
name: simple-app
data:
hello_msg: friend
Loading

0 comments on commit 638f8ed

Please sign in to comment.