From 44bb1ae9f027dec02dd2ec45f88831eabb6f73c8 Mon Sep 17 00:00:00 2001 From: erik Date: Fri, 15 Jul 2022 15:32:14 +0200 Subject: [PATCH] Added base64 encoding to database credentials --- src/main/cljc/dda/c4k_gitea/gitea.cljc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/cljc/dda/c4k_gitea/gitea.cljc b/src/main/cljc/dda/c4k_gitea/gitea.cljc index 1cffaf3..3e1a377 100644 --- a/src/main/cljc/dda/c4k_gitea/gitea.cljc +++ b/src/main/cljc/dda/c4k_gitea/gitea.cljc @@ -58,8 +58,8 @@ (let [{:keys [postgres-db-user postgres-db-password mailer-user mailer-pw]} auth] (-> (yaml/load-as-edn "gitea/secrets.yaml") - (cm/replace-all-matching-values-by-new-value "DBUSER" postgres-db-user) - (cm/replace-all-matching-values-by-new-value "DBPW" postgres-db-password) + (cm/replace-all-matching-values-by-new-value "DBUSER" (b64/encode postgres-db-user)) + (cm/replace-all-matching-values-by-new-value "DBPW" (b64/encode postgres-db-password)) (cm/replace-all-matching-values-by-new-value "MAILERUSER" (b64/encode mailer-user)) (cm/replace-all-matching-values-by-new-value "MAILERPW" (b64/encode mailer-pw)))))