fix the tests

This commit is contained in:
jem 2021-09-29 18:58:48 +02:00
parent e1ef688e5a
commit 2966c2f0bf
2 changed files with 4 additions and 25 deletions

View file

@ -42,28 +42,7 @@
:imagePullPolicy "IfNotPresent" :imagePullPolicy "IfNotPresent"
:command ["/entrypoint.sh"] :command ["/entrypoint.sh"]
:env :env
[{:name "POSTGRES_USER" [{:name "AWS_DEFAULT_REGION"
:valueFrom
{:secretKeyRef
{:name "postgres-secret"
:key "postgres-user"}}}
{:name "POSTGRES_PASSWORD"
:valueFrom
{:secretKeyRef
{:name "postgres-secret"
:key "postgres-password"}}}
{:name "POSTGRES_DB"
:valueFrom
{:configMapKeyRef
{:name "postgres-config"
:key "postgres-db"}}}
{:name "POSTGRES_HOST"
:value "postgresql-service:5432"}
{:name "POSTGRES_SERVICE"
:value "postgresql-service"}
{:name "POSTGRES_PORT"
:value "5432"}
{:name "AWS_DEFAULT_REGION"
:value "eu-central-1"} :value "eu-central-1"}
{:name "AWS_ACCESS_KEY_ID_FILE" {:name "AWS_ACCESS_KEY_ID_FILE"
:value "/var/run/secrets/backup-secrets/aws-access-key-id"} :value "/var/run/secrets/backup-secrets/aws-access-key-id"}

View file

@ -5,7 +5,7 @@
[dda.c4k-jira.core :as cut])) [dda.c4k-jira.core :as cut]))
(deftest should-k8s-objects (deftest should-k8s-objects
(is (= 16 (is (= 15
(count (cut/k8s-objects {:fqdn "jira-neu.prod.meissa-gmbh.de" (count (cut/k8s-objects {:fqdn "jira-neu.prod.meissa-gmbh.de"
:postgres-db-user "jira" :postgres-db-user "jira"
:postgres-db-password "jira-db-password" :postgres-db-password "jira-db-password"
@ -16,7 +16,7 @@
:aws-secret-access-key "aws-secret" :aws-secret-access-key "aws-secret"
:restic-password "restic-pw" :restic-password "restic-pw"
:restic-repository "restic-repository"})))) :restic-repository "restic-repository"}))))
(is (= 14 (is (= 13
(count (cut/k8s-objects {:fqdn "jira-neu.prod.meissa-gmbh.de" (count (cut/k8s-objects {:fqdn "jira-neu.prod.meissa-gmbh.de"
:postgres-db-user "jira" :postgres-db-user "jira"
:postgres-db-password "jira-db-password" :postgres-db-password "jira-db-password"
@ -25,7 +25,7 @@
:aws-secret-access-key "aws-secret" :aws-secret-access-key "aws-secret"
:restic-password "restic-pw" :restic-password "restic-pw"
:restic-repository "restic-repository"})))) :restic-repository "restic-repository"}))))
(is (= 11 (is (= 10
(count (cut/k8s-objects {:fqdn "jira-neu.prod.meissa-gmbh.de" (count (cut/k8s-objects {:fqdn "jira-neu.prod.meissa-gmbh.de"
:postgres-db-user "jira" :postgres-db-user "jira"
:postgres-db-password "jira-db-password" :postgres-db-password "jira-db-password"