From 72f425f30fb35ac565998b0a7e5c442190f2d9b1 Mon Sep 17 00:00:00 2001 From: fstagni Date: Wed, 29 Nov 2023 16:08:56 +0100 Subject: [PATCH] test: added CEs to the integration tests --- .github/workflows/integration.yml | 65 +++++++++++++++++++++++++++++-- 1 file changed, 61 insertions(+), 4 deletions(-) diff --git a/.github/workflows/integration.yml b/.github/workflows/integration.yml index d94d6993..f93e0c5f 100644 --- a/.github/workflows/integration.yml +++ b/.github/workflows/integration.yml @@ -110,9 +110,18 @@ jobs: python dirac-pilot.py -M 1 -S DIRAC-Certification -N jenkins.cern.ch -Q jenkins-queue_not_important -n DIRAC.Jenkins.ch --preinstalledEnvPrefix=/cvmfs/dirac.egi.eu/dirac --cert --certLocation=${GITHUB_WORKSPACE}/Pilot/etc/grid-security --wnVO=dteam --pilotUUID="${pilotUUID}" --debug - integration-cvmfs_no_env: + integration-cvmfs_no_env_CEs: runs-on: ubuntu-latest + strategy: + matrix: + ce: + - jenkins.cern.ch + - jenkins-singularity.cern.ch + - jenkins-mp.cern.ch + - jenkins-mp-pool.cern.ch + - jenkins-mp-pool-singularity.cern.ch + steps: - uses: actions/checkout@v4 - uses: cvmfs-contrib/github-action-cvmfs@v3 @@ -137,7 +146,7 @@ jobs: cd Pilot cp ../tests/CI/pilot_newSchema.json pilot.json sed -i "s/VAR_JENKINS_SITE/DIRAC.Jenkins.ch/g" pilot.json - sed -i "s/VAR_JENKINS_CE/jenkins.cern.ch/g" pilot.json + sed -i "s/VAR_JENKINS_CE/${{ matrix.ce }}/g" pilot.json sed -i "s/VAR_JENKINS_QUEUE/jenkins-queue_not_important/g" pilot.json sed -i "s/VAR_DIRAC_VERSION/${version}/g" pilot.json sed -i "s#VAR_CS#https://lbcertifdirac70.cern.ch:9135/Configuration/Server#g" pilot.json @@ -146,8 +155,7 @@ jobs: g_job="testintegrationworkflow${GITHUB_JOB//-/}" pilotUUID="${g_job//_/}""${GITHUB_RUN_ID}" pilotUUID=$(echo $pilotUUID | rev | cut -c 1-32 | rev) - python dirac-pilot.py -M 1 -S DIRAC-Certification -N jenkins.cern.ch -Q jenkins-queue_not_important -n DIRAC.Jenkins.ch --preinstalledEnvPrefix=/cvmfs/dirac.egi.eu/dirac --cert --certLocation=${GITHUB_WORKSPACE}/Pilot/etc/grid-security --wnVO=dteam -o cvmfsOnly --pilotUUID="${pilotUUID}" --debug - + python dirac-pilot.py -M 1 -S DIRAC-Certification -N ${{ matrix.ce }} -Q jenkins-queue_not_important -n DIRAC.Jenkins.ch --preinstalledEnvPrefix=/cvmfs/dirac.egi.eu/dirac --cert --certLocation=${GITHUB_WORKSPACE}/Pilot/etc/grid-security --wnVO=dteam -o cvmfsOnly --pilotUUID="${pilotUUID}" --debug matching: @@ -247,6 +255,55 @@ jobs: python dirac-pilot.py -M 1 -S DIRAC-Certification -N jenkins-full.cern.ch -Q jenkins-queue_not_important -n DIRAC.Jenkins.ch --preinstalledEnvPrefix=/cvmfs/dirac.egi.eu/dirac --cert --certLocation=${GITHUB_WORKSPACE}/Pilot/etc/grid-security --wnVO=${{ matrix.VO }} -o cvmfsOnly --pilotUUID="${pilotUUID}" --debug + integration-cvmfs_matching_CEs: + runs-on: ubuntu-latest + + strategy: + matrix: + ce: + - jenkins-full.cern.ch + - jenkins-singularity-full.cern.ch + - jenkins-mp-full.cern.ch + - jenkins-mp-pool-full.cern.ch + - jenkins-mp-pool-singularity-full.cern.ch + + steps: + - uses: actions/checkout@v4 + - uses: cvmfs-contrib/github-action-cvmfs@v3 + + - name: Test CernVM-FS + run: ls /cvmfs/dirac.egi.eu + + - name: Retrieve the secret and decode it to a file + env: + HOSTCERT_BASE64: ${{ secrets.HOSTCERT_BASE64 }} + HOSTKEY_BASE64: ${{ secrets.HOSTKEY_BASE64 }} + run: | + cd Pilot + mkdir -p etc/grid-security + echo "$HOSTCERT_BASE64" | base64 --decode > etc/grid-security/hostcert.pem + echo "$HOSTKEY_BASE64" | base64 --decode > etc/grid-security/hostkey.pem + chmod 440 etc/grid-security/hostcert.pem + chmod 400 etc/grid-security/hostkey.pem + - name: tests + run: | + version=$(curl -s "https://api.github.com/repos/DIRACGrid/DIRAC/releases" | jq -r '.[].tag_name' | sort -V | grep 'a' | tail -n 1) + echo ${version} + cd Pilot + cp ../tests/CI/pilot_newSchema.json pilot.json + sed -i "s/VAR_JENKINS_SITE/DIRAC.Jenkins.ch/g" pilot.json + sed -i "s/VAR_JENKINS_CE/${{ matrix.ce }}/g" pilot.json + sed -i "s/VAR_JENKINS_QUEUE/jenkins-queue_not_important/g" pilot.json + sed -i "s/VAR_DIRAC_VERSION/${version}/g" pilot.json + sed -i "s#VAR_CS#https://lbcertifdirac70.cern.ch:9135/Configuration/Server#g" pilot.json + sed -i "s#VAR_USERDN#/DC=ch/DC=cern/OU=Organic Units/OU=Users/CN=alboyer/CN=819281/CN=Alexandre Franck Boyer#g" pilot.json + sed -i "s#VAR_USERDN_GRIDPP#${DIRACUSERDN_GRIDPP}#g" pilot.json + g_job="testintegrationworkflow${GITHUB_JOB//-/}" + pilotUUID="${g_job//_/}""${GITHUB_RUN_ID}" + pilotUUID=$(echo $pilotUUID | rev | cut -c 1-32 | rev) + python dirac-pilot.py -M 1 -S DIRAC-Certification -N ${{ matrix.ce }} -Q jenkins-queue_not_important -n DIRAC.Jenkins.ch --preinstalledEnvPrefix=/cvmfs/dirac.egi.eu/dirac --StopAfterFailedMatches=1 --cert --certLocation=${GITHUB_WORKSPACE}/Pilot/etc/grid-security --wnVO=dteam -o cvmfsOnly --pilotUUID="${pilotUUID}" --debug + + ################################## ### # extensions tests ##################################