Skip to content

Bump github.com/spf13/cast from 1.5.1 to 1.6.0 #1913

Bump github.com/spf13/cast from 1.5.1 to 1.6.0

Bump github.com/spf13/cast from 1.5.1 to 1.6.0 #1913

Workflow file for this run

##################################################################################
#
# This file is automatically generated using templates. Changes to this file
# should happen through editing the templates under .action_templates/*
# Manual edits will be overwritten.
#
##################################################################################
name: Run E2E
on:
# template: .action_templates/events/on-pull-request-master.yaml
pull_request:
branches:
- master
paths-ignore:
- docs/**
# template: .action_templates/events/on-push-master.yaml
push:
branches:
- master
paths-ignore:
- docs/**
# template: .action_templates/events/workflow-dispatch.yaml
workflow_dispatch: {}
jobs:
# template: .action_templates/jobs/display-github-context.yaml
action-context:
if: always()
runs-on: ubuntu-latest
steps:
- name: Dump GitHub context
env:
GITHUB_CONTEXT: ${{ toJSON(github) }}
run: echo "$GITHUB_CONTEXT"
# template: .action_templates/jobs/setup.yaml
setup:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- pipeline-argument: operator
- pipeline-argument: version-upgrade-hook
- pipeline-argument: readiness-probe
- pipeline-argument: agent
- pipeline-argument: e2e
if: github.event_name == 'workflow_dispatch' || github.ref == 'refs/heads/master'
|| (github.event.pull_request.head.repo.full_name == github.repository && github.actor
!= 'dependabot[bot]')
steps:
# template: .action_templates/steps/cancel-previous.yaml
- name: Cancel Previous Runs
uses: styfle/cancel-workflow-action@89f242ee29e10c53a841bfe71cc0ce7b2f065abc # 0.9.0
with:
access_token: ${{ github.token }}
# template: .action_templates/steps/checkout.yaml
- name: Checkout Code
uses: actions/checkout@v2
with:
submodules: true
# template: .action_templates/steps/setup-and-install-python.yaml
- name: Setup Python
uses: actions/setup-python@v2
with:
python-version: 3.10.4
- name: Cache Dependencies
uses: actions/cache@v2
with:
path: ~/.cache/pip
key: ${{ hashFiles('requirements.txt') }}
- name: Install Python Dependencies
run: pip install -r requirements.txt
# template: .action_templates/steps/quay-login.yaml
- name: Login to Quay.io
uses: docker/login-action@v1
with:
registry: quay.io
username: ${{ secrets.QUAY_USERNAME }}
password: ${{ secrets.QUAY_ROBOT_TOKEN }}
# template: .action_templates/steps/set-up-qemu.yaml
- name: Set up QEMU
uses: docker/setup-qemu-action@v2
# template: .action_templates/steps/build-and-push-development-images.yaml
- name: Build and Push Images
run: |
python pipeline.py --image-name ${{ matrix.pipeline-argument }} --tag ${{ github.run_id }}
env:
MONGODB_COMMUNITY_CONFIG: ${{ github.workspace }}/scripts/ci/config.json
version_id: ${{ github.run_id }}
# template: .action_templates/jobs/tests.yaml
tests:
runs-on: ubuntu-latest
needs: [setup]
strategy:
fail-fast: false
matrix:
include:
- test-name: replica_set
distro: ubi
- test-name: replica_set_enterprise_upgrade_4_5
distro: ubi
- test-name: replica_set_enterprise_upgrade_5_6
distro: ubi
- test-name: replica_set_enterprise_upgrade_6_7
distro: ubi
- test-name: replica_set_recovery
distro: ubi
- test-name: replica_set_mongod_readiness
distro: ubi
- test-name: replica_set_scale
distro: ubi
- test-name: replica_set_scale_down
distro: ubi
- test-name: replica_set_change_version
distro: ubi
- test-name: feature_compatibility_version
distro: ubi
- test-name: prometheus
distro: ubi
- test-name: replica_set_tls
distro: ubi
- test-name: replica_set_tls_recreate_mdbc
distro: ubi
- test-name: replica_set_tls_rotate
distro: ubi
- test-name: replica_set_tls_rotate_delete_sts
distro: ubi
- test-name: replica_set_tls_upgrade
distro: ubi
- test-name: statefulset_arbitrary_config
distro: ubi
- test-name: statefulset_arbitrary_config_update
distro: ubi
- test-name: replica_set_mongod_config
distro: ubi
- test-name: replica_set_cross_namespace_deploy
distro: ubi
cluster-wide: true
- test-name: replica_set_custom_role
distro: ubi
- test-name: replica_set_arbiter
distro: ubi
- test-name: replica_set_custom_persistent_volume
distro: ubi
- test-name: replica_set_mount_connection_string
distro: ubi
- test-name: replica_set_mongod_port_change_with_arbiters
distro: ubi
- test-name: replica_set_operator_upgrade
distro: ubi
- test-name: replica_set_connection_string_options
distro: ubi
- test-name: replica_set_x509
distro: ubi
steps:
# template: .action_templates/steps/cancel-previous.yaml
- name: Cancel Previous Runs
uses: styfle/cancel-workflow-action@89f242ee29e10c53a841bfe71cc0ce7b2f065abc # 0.9.0
with:
access_token: ${{ github.token }}
# template: .action_templates/steps/checkout.yaml
- name: Checkout Code
uses: actions/checkout@v2
with:
submodules: true
# template: .action_templates/steps/set-run-status.yaml
- name: Set default run status
run: echo "::set-output name=last_run_status::pending" > last_run_status
# Tracking of the state of the previous test run is a workaround to the fact that it is not
# possible to re-run a single failed job, only re-running the entire workflow is currently possible.
# This workaround skips jobs if they have already passed.
# see https://github.com/actions/runner/issues/432
- name: Restore last run status
id: last_run
uses: actions/cache@v2
with:
path: last_run_status
key: ${{ github.run_id }}-${{ matrix.test-name }}-${{ matrix.distro }}
- name: Set last run status
id: last_run_status
run: cat last_run_status
# template: .action_templates/steps/setup-and-install-python.yaml
- name: Setup Python
uses: actions/setup-python@v2
with:
python-version: 3.10.4
- name: Cache Dependencies
uses: actions/cache@v2
with:
path: ~/.cache/pip
key: ${{ hashFiles('requirements.txt') }}
- name: Install Python Dependencies
run: pip install -r requirements.txt
# template: .action_templates/steps/setup-kind-cluster.yaml
- name: Setup Kind Cluster
run: |
curl -Lo ./kind https://kind.sigs.k8s.io/dl/v0.11.1/kind-linux-amd64
chmod +x ./kind
./kind create cluster
if: steps.last_run_status.outputs.last_run_status != 'success'
- name: Create Directories
run: |
docker exec kind-control-plane mkdir -p /opt/data/mongo-data-0 /opt/data/mongo-data-1 /opt/data/mongo-data-2 /opt/data/mongo-logs-0 /opt/data/mongo-logs-1 /opt/data/mongo-logs-2
if: steps.last_run_status.outputs.last_run_status != 'success'
- name: Install CRD
run: kubectl apply -f config/crd/bases/mongodbcommunity.mongodb.com_mongodbcommunity.yaml
if: steps.last_run_status.outputs.last_run_status != 'success'
# template: .action_templates/steps/run-test-matrix.yaml
- name: Run Test
id: e2e_test
if: steps.last_run_status.outputs.last_run_status != 'success'
run: |
cluster_wide=${{ matrix.cluster-wide }}
if [ -z "$cluster_wide" ]; then
cluster_wide="false"
fi
python3 ./scripts/dev/e2e.py --test ${{ matrix.test-name }} --tag ${{ github.run_id }} --config_file ./scripts/ci/config.json --distro ${{ matrix.distro }} --cluster-wide ${cluster_wide}
# template: .action_templates/steps/save-run-status.yaml
- name: Save run status
if: always()
run: echo "::set-output name=last_run_status::${{ steps.e2e_test.outcome }}"
> last_run_status
# template: .action_templates/steps/dump-and-upload-diagnostics.yaml
- name: Dump Diagnostics
id: dump_diagnostics
if: always() && steps.e2e_test.outcome == 'failure'
continue-on-error: true
run: scripts/ci/dump_diagnostics.sh default # default since kind is running in the default namespace
- name: Upload Diagnostics
if: always() && steps.dump_diagnostics.outcome == 'success'
uses: actions/upload-artifact@v2
continue-on-error: true
with:
name: ${{ matrix.test-name }}-${{ matrix.distro }}-diagnostics
path: ${{ github.workspace }}/diagnostics