diff --git a/osm-seed/templates/db/db-statefulset.yaml b/osm-seed/templates/db/db-statefulset.yaml index 4379041b..dee980ef 100644 --- a/osm-seed/templates/db/db-statefulset.yaml +++ b/osm-seed/templates/db/db-statefulset.yaml @@ -23,7 +23,7 @@ spec: release: {{ .Release.Name }} run: {{ .Release.Name }}-db spec: - priorityClassName: {{ .Values.db.priorityClass | default "high-priority" }} + priorityClassName: {{ .Release.Name }}-{{ .Values.db.priorityClass | default "high-priority" }} containers: - name: {{ .Chart.Name }}-db image: "{{ .Values.db.image.name }}:{{ .Values.db.image.tag }}" diff --git a/osm-seed/templates/jobs/replication-job-deployment.yaml b/osm-seed/templates/jobs/replication-job-deployment.yaml index 336ce2be..1851906c 100644 --- a/osm-seed/templates/jobs/replication-job-deployment.yaml +++ b/osm-seed/templates/jobs/replication-job-deployment.yaml @@ -18,7 +18,7 @@ spec: labels: app: {{ template "osm-seed.name" . }} spec: - priorityClassName: {{ .Values.replicationJob.priorityClass | default "high-priority" }} + priorityClassName: {{ .Release.Name }}-{{ .Values.replicationJob.priorityClass | default "high-priority" }} containers: - name: {{ .Release.Name }}-replication-job-deployment image: {{ .Values.replicationJob.image.name }}:{{ .Values.replicationJob.image.tag }} diff --git a/osm-seed/templates/memcached/memcached-deployment.yml b/osm-seed/templates/memcached/memcached-deployment.yml index 34ccb1a2..cebad86e 100644 --- a/osm-seed/templates/memcached/memcached-deployment.yml +++ b/osm-seed/templates/memcached/memcached-deployment.yml @@ -22,7 +22,7 @@ spec: release: {{ .Release.Name }} run: {{ .Release.Name }}-memcached spec: - priorityClassName: {{ .Values.memcached.priorityClass | default "high-priority" }} + priorityClassName: {{ .Release.Name }}-{{ .Values.memcached.priorityClass | default "high-priority" }} containers: - name: {{ .Chart.Name }}-memcached image: "memcached" diff --git a/osm-seed/templates/nominatim-api/nominatim-api-statefulset.yaml b/osm-seed/templates/nominatim-api/nominatim-api-statefulset.yaml index a402935a..ce3589d6 100644 --- a/osm-seed/templates/nominatim-api/nominatim-api-statefulset.yaml +++ b/osm-seed/templates/nominatim-api/nominatim-api-statefulset.yaml @@ -23,7 +23,7 @@ spec: release: {{ .Release.Name }} run: {{ .Release.Name }}-nominatim-api spec: - priorityClassName: {{ .Values.nominatimApi.priorityClass | default "medium-priority" }} + priorityClassName: {{ .Release.Name }}-{{ .Values.nominatimApi.priorityClass | default "medium-priority" }} containers: - name: {{ .Chart.Name }}-nominatim-api image: "{{ .Values.nominatimApi.image.name }}:{{ .Values.nominatimApi.image.tag }}" diff --git a/osm-seed/templates/osmcha-app/deployment.yaml b/osm-seed/templates/osmcha-app/deployment.yaml index 25a06344..52475326 100644 --- a/osm-seed/templates/osmcha-app/deployment.yaml +++ b/osm-seed/templates/osmcha-app/deployment.yaml @@ -36,7 +36,7 @@ spec: volumeMounts: - name: staticfiles mountPath: /app/staticfiles - priorityClassName: {{ .Values.osmchaApi.priorityClass | default "medium-priority" }} + priorityClassName: {{ .Release.Name }}-{{ .Values.osmchaApi.priorityClass | default "medium-priority" }} containers: - name: osmcha-api image: "{{ .Values.osmchaApi.image.name }}:{{ .Values.osmchaApi.image.tag }}" diff --git a/osm-seed/templates/osmcha-db/osmcha-db-statefulset.yaml b/osm-seed/templates/osmcha-db/osmcha-db-statefulset.yaml index e8bbeada..c196ce25 100644 --- a/osm-seed/templates/osmcha-db/osmcha-db-statefulset.yaml +++ b/osm-seed/templates/osmcha-db/osmcha-db-statefulset.yaml @@ -31,7 +31,7 @@ spec: volumeMounts: - name: postgres-storage mountPath: /var/lib/postgresql/data - priorityClassName: {{ .Values.osmchaDb.priorityClass | default "medium-priority" }} + priorityClassName: {{ .Release.Name }}-{{ .Values.osmchaDb.priorityClass | default "medium-priority" }} containers: - name: {{ .Chart.Name }}-osmcha-db image: "{{ .Values.osmchaDb.image.name }}:{{ .Values.osmchaDb.image.tag }}" diff --git a/osm-seed/templates/overpass-api/overpass-api-statefulset.yaml b/osm-seed/templates/overpass-api/overpass-api-statefulset.yaml index 2de9640a..586fb958 100644 --- a/osm-seed/templates/overpass-api/overpass-api-statefulset.yaml +++ b/osm-seed/templates/overpass-api/overpass-api-statefulset.yaml @@ -23,7 +23,7 @@ spec: release: {{ .Release.Name }} run: {{ .Release.Name }}-overpass-api spec: - priorityClassName: {{ .Values.overpassApi.priorityClass | default "medium-priority" }} + priorityClassName: {{ .Release.Name }}-{{ .Values.overpassApi.priorityClass | default "medium-priority" }} containers: - name: {{ .Chart.Name }}-overpass-api image: "{{ .Values.overpassApi.image.name }}:{{ .Values.overpassApi.image.tag }}" diff --git a/osm-seed/templates/priorityclass.yaml b/osm-seed/templates/priorityclass.yaml index 86652f61..16a22356 100644 --- a/osm-seed/templates/priorityclass.yaml +++ b/osm-seed/templates/priorityclass.yaml @@ -1,7 +1,7 @@ apiVersion: scheduling.k8s.io/v1 kind: PriorityClass metadata: - name: high-priority + name: {{ .Release.Name }}-high-priority value: 100000 globalDefault: false description: "High priority for critical services like web and db." @@ -9,7 +9,7 @@ description: "High priority for critical services like web and db." apiVersion: scheduling.k8s.io/v1 kind: PriorityClass metadata: - name: medium-priority + name: {{ .Release.Name }}-medium-priority value: 50000 globalDefault: false description: "Medium priority for important services like Overpass, Tasking Manager, etc." @@ -17,7 +17,7 @@ description: "Medium priority for important services like Overpass, Tasking Mana apiVersion: scheduling.k8s.io/v1 kind: PriorityClass metadata: - name: low-priority + name: {{ .Release.Name }}-low-priority value: 10000 globalDefault: false description: "Low priority for background jobs and caches." diff --git a/osm-seed/templates/taginfo/taginfo-deployment.yaml b/osm-seed/templates/taginfo/taginfo-deployment.yaml index 0e70292e..2acf87df 100644 --- a/osm-seed/templates/taginfo/taginfo-deployment.yaml +++ b/osm-seed/templates/taginfo/taginfo-deployment.yaml @@ -22,7 +22,7 @@ spec: release: {{ .Release.Name }} run: {{ .Release.Name }}-taginfo-web spec: - priorityClassName: {{ .Values.taginfo.priorityClass | default "medium-priority" }} + priorityClassName: {{ .Release.Name }}-{{ .Values.taginfo.priorityClass | default "medium-priority" }} containers: - name: {{ .Chart.Name }}-taginfo image: "{{ .Values.taginfo.image.name }}:{{ .Values.taginfo.image.tag }}" diff --git a/osm-seed/templates/tasking-manager-api/tm-deployment.yaml b/osm-seed/templates/tasking-manager-api/tm-deployment.yaml index 08c79f9e..88e98f06 100644 --- a/osm-seed/templates/tasking-manager-api/tm-deployment.yaml +++ b/osm-seed/templates/tasking-manager-api/tm-deployment.yaml @@ -22,7 +22,14 @@ spec: release: {{ .Release.Name }} run: {{ .Release.Name }}-tasking-manager-api spec: - priorityClassName: {{ .Values.tmApi.priorityClass | default "medium-priority" }} + priorityClassName: {{ .Release.Name }}-{{ .Values.tmApi.priorityClass | default "medium-priority" }} + initContainers: + - name: db-upgrade + image: "{{ .Values.tmApi.image.name }}:{{ .Values.tmApi.image.tag }}" + command: ["flask", "db", "upgrade"] + envFrom: + - configMapRef: + name: {{ .Release.Name }}-tm-common-env containers: - name: {{ .Chart.Name }}-tasking-manager-api image: "{{ .Values.tmApi.image.name }}:{{ .Values.tmApi.image.tag }}" diff --git a/osm-seed/templates/tasking-manager-db/tm-db-statefulset.yaml b/osm-seed/templates/tasking-manager-db/tm-db-statefulset.yaml index b4a25caa..1774d3a0 100644 --- a/osm-seed/templates/tasking-manager-db/tm-db-statefulset.yaml +++ b/osm-seed/templates/tasking-manager-db/tm-db-statefulset.yaml @@ -23,7 +23,7 @@ spec: release: {{ .Release.Name }} run: {{ .Release.Name }}-tasking-manager-db spec: - priorityClassName: {{ .Values.tmDb.priorityClass | default "medium-priority" }} + priorityClassName: {{ .Release.Name }}-{{ .Values.tmDb.priorityClass | default "medium-priority" }} containers: - name: {{ .Chart.Name }}-tm-db image: "{{ .Values.tmDb.image.name }}:{{ .Values.tmDb.image.tag }}" diff --git a/osm-seed/templates/tiler-db/tiler-db-statefulset.yaml b/osm-seed/templates/tiler-db/tiler-db-statefulset.yaml index 34c99287..f9ccd242 100644 --- a/osm-seed/templates/tiler-db/tiler-db-statefulset.yaml +++ b/osm-seed/templates/tiler-db/tiler-db-statefulset.yaml @@ -24,7 +24,7 @@ spec: release: {{ .Release.Name }} run: {{ .Release.Name }}-tiler-db spec: - priorityClassName: {{ .Values.tilerDb.priorityClass | default "medium-priority" }} + priorityClassName: {{ .Release.Name }}-{{ .Values.tilerDb.priorityClass | default "medium-priority" }} containers: - name: {{ .Chart.Name }}-tiler-db image: "{{ .Values.tilerDb.image.name }}:{{ .Values.tilerDb.image.tag }}" diff --git a/osm-seed/templates/tiler-imposm/tiler-imposm-statefulset.yaml b/osm-seed/templates/tiler-imposm/tiler-imposm-statefulset.yaml index 31c9b33d..ade99bd9 100644 --- a/osm-seed/templates/tiler-imposm/tiler-imposm-statefulset.yaml +++ b/osm-seed/templates/tiler-imposm/tiler-imposm-statefulset.yaml @@ -19,7 +19,7 @@ spec: labels: app: {{ .Release.Name }}-tiler-imposm-sts spec: - priorityClassName: {{ .Values.tilerImposm.priorityClass | default "medium-priority" }} + priorityClassName: {{ .Release.Name }}-{{ .Values.tilerImposm.priorityClass | default "medium-priority" }} containers: - name: {{ .Release.Name }}-tiler-imposm-sts image: {{ .Values.tilerImposm.image.name }}:{{ .Values.tilerImposm.image.tag }} diff --git a/osm-seed/templates/tiler-server/tiler-server-deployment.yaml b/osm-seed/templates/tiler-server/tiler-server-deployment.yaml index b4df1019..883ea298 100644 --- a/osm-seed/templates/tiler-server/tiler-server-deployment.yaml +++ b/osm-seed/templates/tiler-server/tiler-server-deployment.yaml @@ -23,7 +23,7 @@ spec: release: {{ .Release.Name }} run: {{ .Release.Name }}-tiler-server spec: - priorityClassName: {{ .Values.tilerServer.priorityClass | default "medium-priority" }} + priorityClassName: {{ .Release.Name }}-{{ .Values.tilerServer.priorityClass | default "medium-priority" }} containers: - name: {{ .Chart.Name }}-tiler-server image: "{{ .Values.tilerServer.image.name }}:{{ .Values.tilerServer.image.tag }}" diff --git a/osm-seed/templates/tiler-server/tiler-server-statefulset.yaml b/osm-seed/templates/tiler-server/tiler-server-statefulset.yaml index 7eae2c82..40cea078 100644 --- a/osm-seed/templates/tiler-server/tiler-server-statefulset.yaml +++ b/osm-seed/templates/tiler-server/tiler-server-statefulset.yaml @@ -24,7 +24,7 @@ spec: release: {{ .Release.Name }} run: {{ .Release.Name }}-tiler-server spec: - priorityClassName: {{ .Values.tilerServer.priorityClass | default "medium-priority" }} + priorityClassName: {{ .Release.Name }}-{{ .Values.tilerServer.priorityClass | default "medium-priority" }} containers: - name: {{ .Chart.Name }}-tiler-server image: "{{ .Values.tilerServer.image.name }}:{{ .Values.tilerServer.image.tag }}" diff --git a/osm-seed/templates/web/web-deployment.yaml b/osm-seed/templates/web/web-deployment.yaml index 5ebc4fe8..43bf25cf 100644 --- a/osm-seed/templates/web/web-deployment.yaml +++ b/osm-seed/templates/web/web-deployment.yaml @@ -22,7 +22,7 @@ spec: release: {{ .Release.Name }} run: {{ .Release.Name }}-web spec: - priorityClassName: {{ .Values.web.priorityClass | default "high-priority" }} + priorityClassName: {{ .Release.Name }}-{{ .Values.web.priorityClass | default "high-priority" }} containers: - name: {{ .Chart.Name }}-web image: "{{ .Values.web.image.name }}:{{ .Values.web.image.tag }}"