Skip to content

Commit

Permalink
Update kubectl auth in matrix test
Browse files Browse the repository at this point in the history
  • Loading branch information
rick-a-lane-ii committed Apr 11, 2024
1 parent abe2348 commit b46555c
Showing 1 changed file with 40 additions and 25 deletions.
65 changes: 40 additions & 25 deletions .github/workflows/matrix.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,53 +20,43 @@ on:
default: 'warning'

jobs:
telepresence_matrix:
telepresence_matrix_gke:
strategy:
matrix:

client_os: [ubuntu]
client_arch: [latest]

client_telepresence_version: ["2.7"]

cluster_telepresence_version: ["none"]
clusters:
- distribution: GKE
version: "1.27"

- distribution: Kubeception
version: "1.27"

- distribution: GKE
version: "1.27"
- version: "1.27"
- version: "1.27"
config: '{ "initialNodeCount" : 2 }'

cluster_telepresence_version: ["none"]

runs-on: ${{ matrix.client_os }}-${{ matrix.client_arch }}
env:
KUBECEPTION_TOKEN: ${{ secrets.KUBECEPTION_TOKEN }}
GKE_CREDENTIALS: ${{ secrets.GOOGLE_APPLICATION_CREDENTIALS }}
steps:
- uses: actions/checkout@v4
- name: Kubectl tool installer
uses: Azure/setup-kubectl@v3
- uses: 'google-github-actions/auth@v2'
with:
# These tests require Kubectl 1.25 or lower since 1.26+ does noe support the GCP auth plugin
version: 'v1.25.3'
credentials_json: ${{ env.GKE_CREDENTIALS }}
- uses: 'google-github-actions/setup-gcloud@v2'
- name: 'Setup gcloud'
env:
USE_GKE_GCLOUD_AUTH_PLUGIN: True
run: |
gcloud components install gke-gcloud-auth-plugin
- uses: Azure/setup-kubectl@v3
- uses: ./provision-cluster
with:
distribution: ${{ matrix.clusters.distribution }}
distribution: GKE
version: ${{ matrix.clusters.version }}
kubeconfig: kubeconfig.yaml
kubeceptionToken: ${{ matrix.clusters.distribution == 'Kubeception' && env.KUBECEPTION_TOKEN }}
gkeCredentials: ${{ matrix.clusters.distribution == 'GKE' && env.GKE_CREDENTIALS }}
gkeCredentials: ${{ env.GKE_CREDENTIALS }}
gkeConfig: ${{ matrix.clusters.config }}

- run: |
echo Testing telepresence client version ${{ matrix.client_telepresence_version }} on ${{ matrix.client_os }} ${{ matrix.client_arch }} against server version ${{ matrix.cluster_telepresence_version }} on ${{ matrix.clusters.distribution }} cluster version ${{ matrix.clusters.version }}
kubectl version
kubectl get pods -A
- name: "validate gke config"
if: ${{ startsWith(matrix.clusters.config, '{') }}
run: |
Expand All @@ -77,3 +67,28 @@ jobs:
echo "Gke config was not used"
exit 1
fi
telepresence_matrix_kubeception:
strategy:
matrix:
client_os: [ubuntu]
client_arch: [latest]
client_telepresence_version: ["2.7"]
cluster_telepresence_version: ["none"]
clusters:
- version: "1.27"
runs-on: ${{ matrix.client_os }}-${{ matrix.client_arch }}
env:
KUBECEPTION_TOKEN: ${{ secrets.KUBECEPTION_TOKEN }}
steps:
- uses: actions/checkout@v4
- uses: Azure/setup-kubectl@v3
- uses: ./provision-cluster
with:
distribution: Kubeception
version: ${{ matrix.clusters.version }}
kubeconfig: kubeconfig.yaml
kubeceptionToken: ${{ env.KUBECEPTION_TOKEN }}
- run: |
echo Testing telepresence client version ${{ matrix.client_telepresence_version }} on ${{ matrix.client_os }} ${{ matrix.client_arch }} against server version ${{ matrix.cluster_telepresence_version }} on ${{ matrix.clusters.distribution }} cluster version ${{ matrix.clusters.version }}
kubectl version
kubectl get pods -A

0 comments on commit b46555c

Please sign in to comment.