forked from vmware-tanzu/servicebinding
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathworkload.yaml
57 lines (55 loc) · 1.33 KB
/
workload.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
# Copyright 2020 VMware, Inc.
# SPDX-License-Identifier: Apache-2.0
---
apiVersion: v1
kind: Service
metadata:
name: spring-petclinic
spec:
ports:
- port: 80
targetPort: 8080
selector:
app: spring-petclinic
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: spring-petclinic
labels:
app: spring-petclinic
spec:
replicas: 1
selector:
matchLabels:
app: spring-petclinic
template:
metadata:
labels:
app: spring-petclinic
spec:
containers:
- name: workload
# built with paketo builder from https://github.com/spring-projects/spring-petclinic
image: ghcr.io/vmware-tanzu/servicebinding/test/petclinic:20200922
env:
# tell the workload to use mysql instead of the default embedded database
- name: SPRING_PROFILES_ACTIVE
value: mysql
ports:
- name: http
containerPort: 8080
livenessProbe:
httpGet:
path: /actuator/health/liveness
port: http
readinessProbe:
httpGet:
path: /actuator/health/readiness
port: http
startupProbe:
httpGet:
path: /actuator/health/liveness
port: http
failureThreshold: 20
periodSeconds: 5