From 4d1502d0925c7e6cfb74a9706b7bdd6f283aaeb5 Mon Sep 17 00:00:00 2001 From: Igor Scheller Date: Wed, 10 Jan 2024 11:27:47 +0100 Subject: [PATCH] CI: Remove api key on db dump --- .gitlab-ci.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 5344a675..7a66c848 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -259,6 +259,9 @@ dump-database: - cd "${DOCROOT}" - ./bin/migrate script: + - >- + mysql -h "${MYSQL_HOST}" -u "${MYSQL_USER}" -p"${MYSQL_PASSWORD}" "${MYSQL_DATABASE}" + -e 'UPDATE users SET api_key="" WHERE name="admin"' - >- mysqldump -h "${MYSQL_HOST}" -u "${MYSQL_USER}" -p"${MYSQL_PASSWORD}" "${MYSQL_DATABASE}" > "${HOMEDIR}/initial-install.sql"