Created
March 29, 2021 00:11
-
-
Save richardsonlima/491ce58ba434544a76d51230183fadbc to your computer and use it in GitHub Desktop.
stack-demo-for-chaos.yaml
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: mongo | |
namespace: richardsonlima-chaos-demo | |
labels: | |
app.kubernetes.io/name: mongo | |
app.kubernetes.io/component: backend | |
spec: | |
selector: | |
matchLabels: | |
app.kubernetes.io/name: mongo | |
app.kubernetes.io/component: backend | |
replicas: 1 | |
template: | |
metadata: | |
labels: | |
app.kubernetes.io/name: mongo | |
app.kubernetes.io/component: backend | |
spec: | |
containers: | |
- name: mongo | |
image: mongo:4.2 | |
args: | |
- --bind_ip | |
- 0.0.0.0 | |
resources: | |
requests: | |
cpu: 100m | |
memory: 100Mi | |
ports: | |
- containerPort: 27017 | |
--- | |
apiVersion: v1 | |
kind: Service | |
metadata: | |
name: mongo | |
namespace: richardsonlima-chaos-demo | |
labels: | |
app.kubernetes.io/name: mongo | |
app.kubernetes.io/component: backend | |
spec: | |
ports: | |
- port: 27017 | |
targetPort: 27017 | |
selector: | |
app.kubernetes.io/name: mongo | |
app.kubernetes.io/component: backend | |
--- | |
apiVersion: apps/v1 | |
kind: Deployment | |
metadata: | |
name: frontend | |
namespace: richardsonlima-chaos-demo | |
labels: | |
app.kubernetes.io/name: guestbook | |
app.kubernetes.io/component: frontend | |
spec: | |
selector: | |
matchLabels: | |
app.kubernetes.io/name: guestbook | |
app.kubernetes.io/component: frontend | |
replicas: 3 | |
template: | |
metadata: | |
labels: | |
app.kubernetes.io/name: guestbook | |
app.kubernetes.io/component: frontend | |
spec: | |
containers: | |
- name: guestbook | |
image: paulczar/gb-frontend:v5 | |
# image: gcr.io/google-samples/gb-frontend:v4 | |
resources: | |
requests: | |
cpu: 100m | |
memory: 100Mi | |
env: | |
- name: GET_HOSTS_FROM | |
value: dns | |
ports: | |
- containerPort: 80 | |
--- | |
apiVersion: v1 | |
kind: Service | |
metadata: | |
name: frontend | |
namespace: richardsonlima-chaos-demo | |
labels: | |
app.kubernetes.io/name: guestbook | |
app.kubernetes.io/component: frontend | |
spec: | |
# if your cluster supports it, uncomment the following to automatically create | |
# an external load-balanced IP for the frontend service. | |
# type: LoadBalancer | |
ports: | |
- port: 80 | |
selector: | |
app.kubernetes.io/name: guestbook | |
app.kubernetes.io/component: frontend |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment