forked from redhat-cop/containers-quickstarts
-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathdeployment.yml
113 lines (113 loc) · 3.1 KB
/
deployment.yml
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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
apiVersion: v1
kind: Template
labels:
template: play-framework-quickstart-rhel
metadata:
annotations:
description: Play Framework builder and sample application
iconClass: icon-play
tags: play,java
name: play-framework-quickstart-rhel
objects:
- apiVersion: v1
kind: Service
metadata:
annotations:
description: The play server's http port.
labels:
application: ${PLAY_APPLICATION_NAME}
name: ${PLAY_APPLICATION_NAME}
spec:
ports:
- name: 8080-tcp
port: 8080
protocol: TCP
targetPort: 8080
selector:
application: ${PLAY_APPLICATION_NAME}
deploymentconfig: ${PLAY_APPLICATION_NAME}
sessionAffinity: None
type: ClusterIP
- apiVersion: v1
kind: Route
metadata:
annotations:
description: Route for application's http service.
labels:
application: ${PLAY_APPLICATION_NAME}
name: ${PLAY_APPLICATION_NAME}
spec:
host: ${PLAY_APPLICATION_HOSTNAME}
port:
targetPort: 8080-tcp
to:
kind: Service
name: ${PLAY_APPLICATION_NAME}
- apiVersion: v1
kind: DeploymentConfig
metadata:
labels:
app: ${PLAY_APPLICATION_NAME}
name: ${PLAY_APPLICATION_NAME}
spec:
replicas: 1
selector:
application: ${PLAY_APPLICATION_NAME}
deploymentconfig: ${PLAY_APPLICATION_NAME}
strategy:
resources: {}
rollingParams:
intervalSeconds: 1
maxSurge: 25%
maxUnavailable: 25%
timeoutSeconds: 600
updatePeriodSeconds: 1
type: Rolling
template:
metadata:
labels:
application: ${PLAY_APPLICATION_NAME}
deploymentconfig: ${PLAY_APPLICATION_NAME}
spec:
containers:
- env:
- name: JAVA_OPTS_EXT
value: ${PLAY_APPLICATION_JAVA_OPTS_EXT}
image: ${PLAY_APPLICATION_NAME}
imagePullPolicy: Always
name: ${PLAY_APPLICATION_NAME}
ports:
- containerPort: 8080
protocol: TCP
resources: {}
terminationMessagePath: /dev/termination-log
dnsPolicy: ClusterFirst
restartPolicy: Always
securityContext: {}
terminationGracePeriodSeconds: 30
test: false
triggers:
- type: ConfigChange
- imageChangeParams:
automatic: true
containerNames:
- ${PLAY_APPLICATION_NAME}
from:
kind: ImageStreamTag
name: ${PLAY_APPLICATION_NAME}:latest
type: ImageChange
parameters:
- description: The name for the Play Framework application.
displayName: Play application name
name: PLAY_APPLICATION_NAME
required: true
value: play-app
- description: 'Custom hostname for Play Framework service route. Leave blank for
default hostname, e.g.: <application-name>-<project>.<default-domain-suffix>'
displayName: Play application route hostname.
name: PLAY_APPLICATION_HOSTNAME
- description: Extra java parameters for the Play Framework application
displayName: Play application Java extra parameters.
name: PLAY_APPLICATION_JAVA_OPTS_EXT
required: false
value: -Dplay.evolutions.db.default.autoApply=true