From fd0481da698114d2032192796e61c198669cedb3 Mon Sep 17 00:00:00 2001 From: Anil Belur Date: Wed, 1 Jun 2022 09:54:05 +1000 Subject: [PATCH] Fix: Update script and Dockerfile Fix URL path indent, add a default ARG to the Dockerfile to remove WARNING. Set the .asc files permissions to jenkins after the sigul has signed the files. Issue-ID: IT-23826 Change-Id: Idfa32e797320e7a580516a4b137202faf5bd37b0 Signed-off-by: Anil Belur --- docker/Dockerfile | 2 ++ releasenotes/notes/fix-url-path-indent-008b2108f8545f09.yaml | 6 ++++++ shell/sigul-sign-dir.sh | 7 +++++-- 3 files changed, 13 insertions(+), 2 deletions(-) create mode 100644 releasenotes/notes/fix-url-path-indent-008b2108f8545f09.yaml diff --git a/docker/Dockerfile b/docker/Dockerfile index a84d564c..7b98dd50 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -1,6 +1,8 @@ FROM centos:7 SHELL ["/bin/bash", "-c"] +ARG SIGN_DIR="${WORKSPACE}/m2repo" + RUN echo $'[fedora-infra-sigul] \n\ name=Fedora builder packages for sigul \n\ baseurl=https://kojipkgs.fedoraproject.org/repos-dist/epel\$releasever-infra/latest/\$basearch/ \n\ diff --git a/releasenotes/notes/fix-url-path-indent-008b2108f8545f09.yaml b/releasenotes/notes/fix-url-path-indent-008b2108f8545f09.yaml new file mode 100644 index 00000000..11ff741d --- /dev/null +++ b/releasenotes/notes/fix-url-path-indent-008b2108f8545f09.yaml @@ -0,0 +1,6 @@ +--- +fixes: + - | + Fix URL path indent, add a default ARG to the Dockerfile to remove WARNING. + Set the .asc files permissions to jenkins after the sigul has signed the + files. diff --git a/shell/sigul-sign-dir.sh b/shell/sigul-sign-dir.sh index 92380cc0..f708d37d 100644 --- a/shell/sigul-sign-dir.sh +++ b/shell/sigul-sign-dir.sh @@ -18,9 +18,9 @@ OS_RELEASE=$(facter lsbdistrelease | tr '[:upper:]' '[:lower:]') if [[ "$OS_RELEASE" == "8" && "$OS" == 'centos' ]]; then # Get Dockerfile and the enterpoint to build the docker image. wget -O "${WORKSPACE}/sigul-sign.sh" "https://raw.githubusercontent.com/"\ - "lfit/releng-global-jjb/master/shell/sigul-sign.sh" +"lfit/releng-global-jjb/master/shell/sigul-sign.sh" wget -O "${WORKSPACE}/Dockerfile" "https://raw.githubusercontent.com/"\ - "lfit/releng-global-jjb/master/docker/Dockerfile" +"lfit/releng-global-jjb/master/docker/Dockerfile" # Setup the docker environment for jenkins user docker build -f ${WORKSPACE}/Dockerfile \ @@ -45,6 +45,9 @@ if [[ "$OS_RELEASE" == "8" && "$OS" == 'centos' ]]; then --mount type=bind,source="/w/workspace",target="/w/workspace" \ --mount type=bind,source="/home/jenkins",target="/home/jenkins" \ -u root:root -w $(pwd) sigul-sign + + # change the .asc files owner permissions back to jenkins + sudo chown -R jenkins:jenkins "${SIGN_DIR}" else lftools sign sigul -m "${SIGN_MODE}" "${SIGN_DIR}" fi -- 2.16.6