From 33b28625dac55a1363dbbc632ea557db0400cfba Mon Sep 17 00:00:00 2001 From: Daan Rosbergen Date: Wed, 22 Sep 2021 10:16:43 +0200 Subject: [PATCH] fix(helm): Remove hardcoded hostname from nc command and use env variable instead. This is an issue when you use an external mysql database. --- k8s/openstad/templates/api/deployment.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/k8s/openstad/templates/api/deployment.yaml b/k8s/openstad/templates/api/deployment.yaml index 0eae8a45..6b6ab909 100644 --- a/k8s/openstad/templates/api/deployment.yaml +++ b/k8s/openstad/templates/api/deployment.yaml @@ -226,7 +226,7 @@ spec: initContainers: - command: ["/bin/sh", "-c"] args: - - nc {{.Release.Name}}-mysql 3306 -z -w1 && node migrate.js; + - nc $API_DATABASE_HOST 3306 -z -w1 && node migrate.js; env: - name: DB_TYPE value: mysql