chore: run one e2e test #15
This file contains 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: e2e | |
env: | |
CI_COMMIT_REF_NAME: ${{ github.ref_name }} | |
# E2E_CLUSTERTRANSPORT_TOKEN: ${{ secrets.E2E_VIRTUALIZATION_SA_TOKEN }} | |
on: | |
pull_request: | |
branches: | |
- ci/tests/e2e-workflow | |
push: | |
branches: | |
- ci/tests/e2e-workflow | |
defaults: | |
run: | |
shell: bash | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.event.number || github.ref }} | |
cancel-in-progress: true | |
jobs: | |
show_dev_manifest: | |
runs-on: ubuntu-latest | |
name: Run e2e | |
steps: | |
- name: Install Task | |
uses: arduino/setup-task@v2 | |
- uses: azure/setup-kubectl@v3 | |
# default is latest stable | |
id: install | |
- uses: actions/checkout@v4 | |
- uses: azure/k8s-set-context@v4 | |
with: | |
method: service-account | |
k8s-url: https://api.e2e.virtlab.flant.com | |
k8s-secret: ${{ secrets.E2E_VIRTUALIZATION_SA_SECRET }} | |
- name: e2e | |
run: | | |
export E2E_CLUSTERTRANSPORT_KUBECONFIG=$KUBECONFIG | |
export E2E_CLUSTERTRANSPORT_ENDPOINT="https://api.e2e.virtlab.flant.com" | |
export E2E_CLUSTERTRANSPORT_TOKEN=${{ secrets.E2E_VIRTUALIZATION_SA_TOKEN }} | |
task e2e:run_one TEST="Label and Annotation" | |
# run: | | |
# kubectl config view -o jsonpath='{"Cluster name\tServer\n"}{range .clusters[*]}{.name}{"\t"}{.cluster.server}{"\n"}{end}' | |
# export CLUSTER_NAME="e2e-cluster" | |
# export E2E_CLUSTERTRANSPORT_ENDPOINT=$(kubectl config view -o jsonpath="{.clusters[?(@.name==\"$CLUSTER_NAME\")].cluster.server}") | |
# export E2E_CLUSTERTRANSPORT_TOKEN=$(echo ${{ secrets.E2E_VIRTUALIZATION_SA_SECRET }} | yq '.data.token' | base64 -d) | |
# echo ${{ secrets.E2E_VIRTUALIZATION_SA_SECRET }} | yq e '.data."ca.crt"' | base64 -d > ca.crt | |
# export E2E_CLUSTERTRANSPORT_CERTIFICATEAUTHORITY="$PWD/ca.crt" | |
# export E2E_CLUSTERTRANSPORT_INSECURETLS="true" | |
# task e2e:run_one TEST="Label and Annotation" | |
# - name: Create Namespace | |
# run: | | |
# kubectl create namespace testgh | |
# - name: Get ns and delete | |
# run: | | |
# kubectl get ns | grep testgh | |
# kubectl delete namespace testgh |