@@ -110,14 +110,83 @@ objects:
110
110
enabled : true
111
111
apiPath : automation-hub
112
112
113
+ - name : " migration${SUFFIX}"
114
+ minReplicas : ${{MIGRATION_REPLICAS}}
115
+ podSpec :
116
+ name : migration
117
+ image : ${IMAGE_NAME}:${IMAGE_TAG}
118
+ args : ['bash', '-c', 'while true; do sleep 86400; done']
119
+ initContainers :
120
+ - args : ['manage', 'migrate']
121
+ inheritEnv : true
122
+ resources :
123
+ limits :
124
+ cpu : ${{MIGRATION_CPU_LIMIT}}
125
+ memory : ${{MIGRATION_MEMORY_LIMIT}}
126
+ requests :
127
+ cpu : ${{MIGRATION_CPU_REQUEST}}
128
+ memory : ${{MIGRATION_MEMORY_REQUEST}}
129
+ livenessProbe :
130
+ exec :
131
+ command :
132
+ - date
133
+ initialDelaySeconds : 30
134
+ timeoutSeconds : 10
135
+ periodSeconds : 30
136
+ successThreshold : 1
137
+ failureThreshold : 6
138
+ readinessProbe :
139
+ exec :
140
+ command :
141
+ - date
142
+ initialDelaySeconds : 30
143
+ timeoutSeconds : 1
144
+ periodSeconds : 30
145
+ successThreshold : 1
146
+ failureThreshold : 3
147
+ env :
148
+ - name : PULP_GALAXY_DEPLOYMENT_MODE
149
+ value : ' insights'
150
+ - name : PULP_CONTENT_ORIGIN
151
+ value : ${{CONTENT_ORIGIN}}
152
+ - name : PULP_CONTENT_PATH_PREFIX
153
+ value : /api/automation-hub/pulp/content/
154
+ - name : ENABLE_SIGNING
155
+ value : ${ENABLE_SIGNING}
156
+ - name : GNUPGHOME
157
+ value : ${GNUPGHOME}
158
+ volumeMounts :
159
+ - name : pulp-key
160
+ mountPath : /etc/pulp/certs/database_fields.symmetric.key
161
+ subPath : database_fields.symmetric.key
162
+ readOnly : true
163
+ - name : signing-gpg-key
164
+ mountPath : /tmp/ansible-sign.key
165
+ subPath : ansible-sign.key
166
+ readOnly : true
167
+ - name : signing-script
168
+ mountPath : /var/lib/pulp/scripts
169
+ readOnly : true
170
+ volumes :
171
+ - name : pulp-key
172
+ secret :
173
+ secretName : pulp-key
174
+ - name : signing-gpg-key
175
+ secret :
176
+ secretName : signing-gpg-key
177
+ - name : signing-script
178
+ secret :
179
+ defaultMode : 0555
180
+ secretName : signing-script
181
+
113
182
- name : " galaxy-api${SUFFIX}"
114
183
minReplicas : ${{GALAXY_API_REPLICAS}}
115
184
podSpec :
116
185
name : galaxy-api
117
186
image : ${IMAGE_NAME}:${IMAGE_TAG}
118
187
args : ['run', 'api']
119
188
initContainers :
120
- - args : ['manage', 'migrate ']
189
+ - args : ['wait-for-migrations ']
121
190
inheritEnv : true
122
191
resources :
123
192
limits :
@@ -436,6 +505,18 @@ parameters:
436
505
- name : NGINX_CPU_LIMIT
437
506
value : 200m
438
507
508
+ # migration resource requirements
509
+ - name : MIGRATION_REPLICAS
510
+ value : ' 1'
511
+ - name : MIGRATION_MEMORY_REQUEST
512
+ value : 1Gi
513
+ - name : MIGRATION_MEMORY_LIMIT
514
+ value : 2Gi
515
+ - name : MIGRATION_CPU_REQUEST
516
+ value : 200m
517
+ - name : MIGRATION_CPU_LIMIT
518
+ value : ' 1'
519
+
439
520
# galaxy-api resource requirements
440
521
- name : GALAXY_API_REPLICAS
441
522
value : ' 1'
0 commit comments