From d11a2f3bc7418c40d9c9effd59ed987faa42301a Mon Sep 17 00:00:00 2001 From: Tomas Hozza Date: Wed, 23 Mar 2022 07:28:45 +0100 Subject: [PATCH] api.sh: encrypt the DB dump artifact --- test/cases/api.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/cases/api.sh b/test/cases/api.sh index bb7ddd209..73cbbe9f9 100755 --- a/test/cases/api.sh +++ b/test/cases/api.sh @@ -278,7 +278,8 @@ function dump_db() { sudo podman exec osbuild-composer-db psql -U postgres -d osbuildcomposer -c "SELECT * FROM jobs;" | grep "9 rows" # Save the result, including the manifest, for the job, straight from the db - sudo podman exec osbuild-composer-db psql -U postgres -d osbuildcomposer -c "SELECT result FROM jobs WHERE type='manifest-id-only'" | sudo tee "${ARTIFACTS}/build-result.txt" + sudo podman exec osbuild-composer-db psql -U postgres -d osbuildcomposer -c "SELECT result FROM jobs WHERE type='manifest-id-only'" \ + | gpg --batch --yes --passphrase "${GPG_SYMMETRIC_PASSPHRASE}" -o "${ARTIFACTS}/build-result.gpg" --symmetric - set -x }