-
Notifications
You must be signed in to change notification settings - Fork 2
/
deployment.yaml
39 lines (39 loc) · 999 Bytes
/
deployment.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
apiVersion: apps/v1
kind: Deployment
metadata:
name: spring-petclinic-deployment
labels:
app: spring-petclinic
spec:
replicas: 1
selector:
matchLabels:
app: spring-petclinic
template:
metadata:
labels:
app: spring-petclinic
spec:
imagePullSecrets:
- name: $KUBERNETES_SECRET_NAME
containers:
- name: spring-petclinic
image: <my_dockerhub_username>/spring-petclinic:latest
ports:
- containerPort: 8080
env:
- name: PETCLINIC_DB_HOST
valueFrom:
secretKeyRef:
name: jenkins-petclinic-ddbb-host
key: host
- name: PETCLINIC_DB_USER
valueFrom:
secretKeyRef:
name: jenkins-petclinic-ddbb
key: username
- name: PETCLINIC_DB_PASSWORD
valueFrom:
secretKeyRef:
name: jenkins-petclinic-ddbb
key: password