From 6e9d297f02e8fb8875416d32da1d52a9dea39e9a Mon Sep 17 00:00:00 2001 From: Jens Langhammer Date: Sun, 23 Feb 2020 20:12:48 +0100 Subject: [PATCH] deploy: use new bootstrap command --- docker-compose.yml | 4 ++++ helm/templates/web-deployment.yaml | 9 +++++++-- helm/templates/worker-deployment.yaml | 4 +++- 3 files changed, 14 insertions(+), 3 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index ff248cb4f..e1b3c04c6 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -23,6 +23,8 @@ services: server: image: beryju/passbook:${SERVER_TAG:-latest} command: + - ./manage.py + - bootstrap - uwsgi - uwsgi.ini environment: @@ -42,6 +44,8 @@ services: worker: image: beryju/passbook:${SERVER_TAG:-latest} command: + - ./manage.py + - bootstrap - celery - worker - --autoscale=10,3 diff --git a/helm/templates/web-deployment.yaml b/helm/templates/web-deployment.yaml index 25f8efac9..82cca7e79 100644 --- a/helm/templates/web-deployment.yaml +++ b/helm/templates/web-deployment.yaml @@ -27,9 +27,12 @@ spec: initContainers: - name: passbook-database-migrations image: "beryju/passbook:{{ .Values.image.tag }}" + imagePullPolicy: Always command: - ./manage.py args: + - bootstrap + - ./manage.py - migrate volumeMounts: - mountPath: /etc/passbook @@ -57,10 +60,12 @@ spec: containers: - name: {{ .Chart.Name }} image: "beryju/passbook:{{ .Values.image.tag }}" - imagePullPolicy: IfNotPresent + imagePullPolicy: Always command: - - uwsgi + - ./manage.py args: + - bootstrap + - uwsgi - uwsgi.ini volumeMounts: - mountPath: /etc/passbook diff --git a/helm/templates/worker-deployment.yaml b/helm/templates/worker-deployment.yaml index f1ec43f1c..78fc9fe93 100644 --- a/helm/templates/worker-deployment.yaml +++ b/helm/templates/worker-deployment.yaml @@ -29,8 +29,10 @@ spec: image: "beryju/passbook:{{ .Values.image.tag }}" imagePullPolicy: IfNotPresent command: - - celery + - ./manage.py args: + - bootstrap + - celery - worker - --autoscale=10,3 - -E