test(e2e): fix the restore-flow races and retry-worker cascade #933
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| --- | |
| name: validate-devcontainer | |
| permissions: | |
| contents: read | |
| packages: write | |
| concurrency: | |
| group: validate-devcontainer-${{ github.ref }} | |
| cancel-in-progress: true | |
| on: | |
| push: | |
| branches: | |
| - "**" | |
| - "!main" | |
| env: | |
| CACHE_IMAGE_PREFIX: ghcr.io/${{ github.repository }} | |
| jobs: | |
| # detect changes in devcontainer files | |
| detect-changes: | |
| runs-on: ubuntu-latest | |
| env: | |
| IS_CI_AUTOMATION: "yes" | |
| outputs: | |
| devcontainer-changed: ${{ steps.check.outputs.devcontainer-changed }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: dorny/paths-filter@v3 | |
| id: check | |
| with: | |
| filters: | | |
| devcontainer-changed: | |
| - '.devcontainer/**' | |
| - '.github/workflows/validate-devcontainer.yml' | |
| # Build and cache devcontainer test build for faster CI stages | |
| devcontainer-test-build: | |
| needs: detect-changes | |
| runs-on: ubuntu-latest | |
| if: needs.detect-changes.outputs.devcontainer-changed == 'true' | |
| steps: | |
| - name: Checkout (GitHub) | |
| uses: actions/checkout@v4 | |
| - name: Login to GitHub Container Registry | |
| uses: docker/login-action@v3 | |
| with: | |
| registry: ghcr.io | |
| username: ${{ github.repository_owner }} | |
| password: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Build and cache devcontainer | |
| uses: devcontainers/ci@v0.3 | |
| with: | |
| # Change this to point to your image name | |
| imageName: ${{ env.CACHE_IMAGE_PREFIX }}/cached-devcontainer-test | |
| push: always | |
| test-devcontainer-binaries-exist: | |
| # Test that expected binaries exist in the devcontainer, using the cached devcontainer test build | |
| runs-on: ubuntu-latest | |
| needs: devcontainer-test-build | |
| container: | |
| image: ghcr.io/${{ github.repository }}/cached-devcontainer-test:latest | |
| steps: | |
| - name: Checkout (GitHub) | |
| uses: actions/checkout@v4 | |
| - name: devcontainer test binaries | |
| run: | | |
| ./.devcontainer/check_binaries.sh |