From 22a0ea850435d0f4ca4326b7525c5a0fa1d1d8a5 Mon Sep 17 00:00:00 2001 From: Matthew Richards Date: Thu, 3 Feb 2022 16:58:30 +0000 Subject: [PATCH] ci: add anon user to ICAT Server rootUserNames #268 --- .github/workflows/ci-build.yml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/.github/workflows/ci-build.yml b/.github/workflows/ci-build.yml index 1d9a4a47..ddcff9d1 100644 --- a/.github/workflows/ci-build.yml +++ b/.github/workflows/ci-build.yml @@ -59,6 +59,17 @@ jobs: run: | ansible-playbook icat-ansible/icatdb-minimal-hosts.yml -i icat-ansible/hosts --vault-password-file icat-ansible/vault_pass.txt -vv + # rootUserNames needs editing as anon/anon is used in search API and required to pass endpoint tests + - name: Add anon user to rootUserNames + run: | + awk -F" =" '/rootUserNames/{$2="= simple/root anon/anon";print;next}1' /home/runner/install/icat.server/run.properties > /home/runner/install/icat.server/run.properties.tmp + - name: Apply rootUserNames change + run: | + mv -f /home/runner/install/icat.server/run.properties.tmp /home/runner/install/icat.server/run.properties + - name: Reinstall ICAT Server + run: | + cd /home/runner/install/icat.server/ && ./setup -vv install + - name: Checkout DataGateway API uses: actions/checkout@v2