Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: test the e2e using a self-hosted runner #308

Merged
merged 1 commit into from
Dec 11, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
48 changes: 48 additions & 0 deletions .github/workflows/e2e-long-test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
name: Run nightly e2e tests (using runner)

on:
workflow_dispatch:

concurrency: ci_e2e_tests

env:
NGROK_AUTHTOKEN: ${{ secrets.NGROK_AUTHTOKEN }}
NGROK_API_KEY: ${{ secrets.NGROK_API_KEY }}
RANCHER_HOSTNAME: ${{ secrets.NGROK_DOMAIN }}
RANCHER_PASSWORD: ${{ secrets.RANCHER_PASSWORD }}
CAPA_ENCODED_CREDS: ${{ secrets.CAPA_ENCODED_CREDS }}
AZURE_SUBSCRIPTION_ID: ${{ secrets.AZURE_SUBSCRIPTION_ID }}
AZURE_CLIENT_ID: ${{ secrets.AZURE_CLIENT_ID }}
AZURE_CLIENT_SECRET: ${{ secrets.AZURE_CLIENT_SECRET }}
AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }}

jobs:
e2e:
runs-on: [self-hosted, linux]
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: setupGo
uses: actions/setup-go@v4
with:
go-version: '=1.20.7'
- name: Run e2e tests
run: make test-e2e
- name: Collect run artifacts
if: always()
uses: actions/upload-artifact@v3
with:
name: artifacts
path: _artifacts
- name: Cleanup Azure Resources
if: always()
uses: rancher-sandbox/azure-janitor@v0.1.1
with:
resource-groups: highlander-e2e*
subscription-id: ${{ secrets.AZURE_SUBSCRIPTION_ID}}
client-id: ${{ secrets.AZURE_CLIENT_ID}}
client-secret: ${{ secrets.AZURE_CLIENT_SECRET}}
tenant-id: ${{ secrets.AZURE_TENANT_ID}}
commit: true