Skip to content

Fix race condition in intercept handling when InterceptInfo is updated concurrently #3041

Fix race condition in intercept handling when InterceptInfo is updated concurrently

Fix race condition in intercept handling when InterceptInfo is updated concurrently #3041

Workflow file for this run

name: "Integration Tests"
on:
pull_request:
types:
- labeled
permissions:
contents: read
pull-requests: write
env:
TELEPRESENCE_REGISTRY: local
jobs:
build_and_test:
if: ${{ github.event.label.name == 'ok to test' || github.event.label.name == 'compatibility test' }}
strategy:
fail-fast: false
matrix:
runners:
- ubuntu-latest
# Re-enable when we can run a proper cluster. Colima almost works on macOS but the very limited
# resources available make the test fail very often. On windows, we'll need WSL2
# - macos-latest
# - windows-latest
runs-on: ${{ matrix.runners }}
steps:
- name: Remove ok to test label
if: github.event.label.name == 'ok to test'
uses: buildsville/add-remove-label@v2.0.1
with:
token: ${{ secrets.GITHUB_TOKEN }}
labels: ok to test
type: remove
- name: Remove compatibility test label
if: github.event.label.name == 'compatibility test'
uses: buildsville/add-remove-label@v2.0.1
with:
token: ${{ secrets.GITHUB_TOKEN }}
labels: compatibility test
type: remove
- uses: actions/checkout@v4
with:
fetch-depth: 0
ref: "${{ github.event.pull_request.head.sha }}"
- name: install dependencies
uses: ./.github/actions/install-dependencies
- name: Get Telepresence Version
id: version
run: |
v=$(go run build-aux/genversion/main.go ${{github.run_id}})
echo "TELEPRESENCE_VERSION=$v" >> "$GITHUB_ENV"
echo "TELEPRESENCE_SEMVER=${v#v}" >> "$GITHUB_ENV"
- name: Start minikube
if: runner.os == 'Linux'
uses: medyagh/setup-minikube@latest
with:
kubernetes-version: v1.33.5
- name: Build client
run: make build
- name: Build images
run: make client-image tel2-image
- name: Load images into minikube
run: |
minikube image load ${{env.TELEPRESENCE_REGISTRY}}/telepresence:${{env.TELEPRESENCE_SEMVER}}
minikube image load ${{env.TELEPRESENCE_REGISTRY}}/tel2:${{env.TELEPRESENCE_SEMVER}}
- name: Run integration tests
if: github.event.label.name == 'ok to test'
uses: nick-fields/retry/@v3
with:
max_attempts: 3
shell: bash
timeout_minutes: 90
command: |
set -ex
if [[ ${RUNNER_OS} == "Windows" ]]; then
export PATH="$PATH:/C/Program Files/SSHFS-Win/bin:$HOME/kubectl-plugins"
fi
make check-integration
- name: Compatibility with older manager and agent
if: ${{ github.event.label.name == 'compatibility test' }}
env:
DEV_MANAGER_VERSION: "2.24.1"
DEV_MANAGER_REGISTRY: ghcr.io/telepresenceio
uses: nick-fields/retry/@v3
with:
max_attempts: 3
shell: bash
timeout_minutes: 90
command: |
set -ex
if [[ ${RUNNER_OS} == "Windows" ]]; then
export PATH="$PATH:/C/Program Files/SSHFS-Win/bin:$HOME/kubectl-plugins"
fi
make check-integration
- name: Compatibility with older client
if: ${{ github.event.label.name == 'compatibility test' }}
env:
DEV_CLIENT_VERSION: "2.24.1"
DEV_CLIENT_REGISTRY: ghcr.io/telepresenceio
uses: nick-fields/retry/@v3
with:
max_attempts: 3
shell: bash
timeout_minutes: 90
command: |
set -ex
if [[ ${RUNNER_OS} == "Windows" ]]; then
export PATH="$PATH:/C/Program Files/SSHFS-Win/bin:$HOME/kubectl-plugins"
fi
make check-integration
- uses: ./.github/actions/upload-logs
env:
LOG_SUFFIX: "${{ runner.os }}-${{ runner.arch }}-${{ matrix.clusters.distribution }}-${{ matrix.clusters.version }}"
if: ${{ always() }}