@@ -345,3 +345,96 @@ jobs:
345345 password : ${{ secrets.ARTIFACTS_PASSWORD }}
346346 source : /tmp/artifacts
347347 if : always()
348+
349+ sse-kms-migration-tests :
350+ strategy :
351+ matrix :
352+ include :
353+ - kmsHideScalityArn : ' showArn'
354+ job-name : sse-kms-migration-tests-show-arn
355+ - kmsHideScalityArn : ' hideArn'
356+ job-name : sse-kms-migration-tests-hide-arn
357+ name : ${{ matrix.job-name }}
358+ runs-on : ubuntu-latest
359+ needs : build
360+ env :
361+ S3BACKEND : file
362+ S3VAULT : mem
363+ CLOUDSERVER_IMAGE_BEFORE_SSE_MIGRATION : ghcr.io/${{ github.repository }}:7.70.21-11-svc-base
364+ CLOUDSERVER_IMAGE : ghcr.io/${{ github.repository }}:${{ github.sha }}
365+ MPU_TESTING : " yes"
366+ # ENABLE_NULL_VERSION_COMPAT_MODE: "${{ matrix.enable-null-compat }}"
367+ JOB_NAME : ${{ matrix.job-name }}
368+ steps :
369+ - name : Checkout
370+ uses : actions/checkout@v4
371+ - uses : actions/setup-python@v5
372+ with :
373+ python-version : 3.9
374+ - name : Setup CI environment
375+ uses : ./.github/actions/setup-ci
376+ - name : Setup matrix job artifacts directory
377+ shell : bash
378+ run : |
379+ set -exu
380+ mkdir -p /tmp/artifacts/${{ matrix.job-name }}/
381+ # - name: Setup python test environment
382+ # run: |
383+ # sudo apt-get install -y libdigest-hmac-perl
384+ # pip install 's3cmd==2.3.0'
385+ - name : Setup CI services (with old cloudserver image before sse migration)
386+ run : docker compose up -d
387+ working-directory : .github/docker
388+ env :
389+ CLOUDSERVER_IMAGE : ${{ CLOUDSERVER_IMAGE_BEFORE_SSE_MIGRATION }}
390+ SSE_CONF : before
391+ - name : Run SSE before migration tests (setup buckets and objects)
392+ env :
393+ S3_CONFIG_FILE=tests/functional/kms-sse-migration/config.old.json
394+ run : |-
395+ set -o pipefail;
396+ bash wait_for_local_port.bash 8000 40
397+
398+ # ensures the expected version of cloudserver is old one
399+ VERSION=$(docker compose exec cloudserver cat package.json | jq -r .version)
400+ if [[ "$VERSION" != "7.70.21-11" ]]; then
401+ echo "bad version of container. Should be 7.70.21-11. Was $VERSION" > &2
402+ exit 1
403+ fi
404+
405+ yarn run ft_sse_before_migration | tee /tmp/artifacts/${{ matrix.job-name }}/beforeMigration.log
406+ - name : Replace old cloudserver image with current one
407+ run : docker compose down cloudserver && docker compose up -d cloudserver
408+ working-directory : .github/docker
409+ env :
410+ SSE_CONF : sseMigration.${{ kmsHideScalityArn }}
411+ - name : Run SSE migration tests
412+ env :
413+ S3_CONFIG_FILE=tests/functional/kms-sse-migration/config.sseMigration.${{ kmsHideScalityArn }}.json
414+ run : |-
415+ set -o pipefail;
416+ bash wait_for_local_port.bash 8000 40
417+
418+ # ensures the expected version of cloudserver is not old one
419+ VERSION=$(docker compose exec cloudserver cat package.json | jq -r .version)
420+ if [[ "$VERSION" == "7.70.21-11" ]]; then
421+ echo "bad version of container. Should NOT be 7.70.21-11. Was $VERSION" > &2
422+ exit 1
423+ fi
424+
425+ yarn run ft_sse_migration | tee /tmp/artifacts/${{ matrix.job-name }}/migration.log
426+ - name : Run SSE arnPrefix tests
427+ env :
428+ S3_CONFIG_FILE=tests/functional/kms-sse-migration/config.sseMigration.${{ kmsHideScalityArn }}.json
429+ run : |-
430+ set -o pipefail;
431+ yarn run ft_sse_arn | tee /tmp/artifacts/${{ matrix.job-name }}/arnPrfefix.log
432+ - name : Upload logs to artifacts
433+ uses : scality/action-artifacts@v4
434+ with :
435+ method : upload
436+ url : https://artifacts.scality.net
437+ user : ${{ secrets.ARTIFACTS_USER }}
438+ password : ${{ secrets.ARTIFACTS_PASSWORD }}
439+ source : /tmp/artifacts
440+ if : always()
0 commit comments