Skip to content

🎉 initial preloader version #48

🎉 initial preloader version

🎉 initial preloader version #48

Workflow file for this run

name: e2e_test
on:
pull_request:
branches:
- main
paths:
- "**.go"
- "**.sh"
- "Dockerfile"
- "Makefile"
- "go.*"
- ".github/workflows/e2e_test.yml"
workflow_dispatch:
jobs:
e2e:
runs-on: [self-hosted, linux]
steps:
- name: ⬇️ Checkout repository
uses: actions/checkout@v5
- name: 🔐 Set ak/sk name based on runner region
run: .github/scripts/runneraksk.sh
- name: ⬇️ Install kubectl
uses: azure/setup-kubectl@v4
with:
version: v1.32.9
- name: ⬇️ Install helm
uses: azure/setup-helm@v4
with:
version: v3.18.5
- name: ⬇️ Install Go
uses: actions/setup-go@v5
with:
go-version-file: 'go.mod'
- name: 🧹 Frieza
uses: outscale/frieza-github-actions/frieza-clean@master
with:
access_key: ${{ secrets[env.OSC_ACCESS_KEY_NAME] }}
secret_key: ${{ secrets[env.OSC_SECRET_KEY_NAME] }}
region: ${{ env.OSC_REGION }}
- name: 👷 Deploy test cluster
id: testcluster
uses: outscale/cluster-api-provider-outscale/github_actions/deploy_cluster@main
with:
RUNNER_NAME: ${{ runner.name }}
OKS_ACCESS_KEY: ${{ secrets.OKS_ACCESS_KEY }}
OKS_SECRET_KEY: ${{ secrets.OKS_SECRET_KEY }}
OKS_REGION: ${{ vars.OKS_REGION }}
OSC_ACCESS_KEY: ${{ secrets[env.OSC_ACCESS_KEY_NAME] }}
OSC_SECRET_KEY: ${{ secrets[env.OSC_SECRET_KEY_NAME] }}
OSC_REGION: ${{ env.OSC_REGION }}
CLUSTER_NAME: "k8s-preloader"
IMAGE_NAME: ${{ vars.IMG_KUBERNETES }}
CCM: true
- name: 📦 Build & Push the Docker image
run: |
docker login ${{ vars.REGISTRY }} -u admin -p ${{ secrets.HARBOR_ADMIN_PASSWORD }}
make image-build image-tag image-push
env:
REGISTRY_IMAGE: "${{ vars.REGISTRY }}/outscale/k8s-image-preloader"
IMAGE_TAG: ${{ github.sha }}
REGISTRY_TAG: ${{ github.sha }}
- name: 🔎 Take snapshot
id: snapshot
uses: ./github_actions/preloader_snapshot
with:
KUBECONFIG: ${{ steps.testcluster.outputs.KUBECONFIG }}
OSC_ACCESS_KEY: ${{ secrets[env.OSC_ACCESS_KEY_NAME] }}
OSC_SECRET_KEY: ${{ secrets[env.OSC_SECRET_KEY_NAME] }}
OSC_REGION: ${{ env.OSC_REGION }}
PRELOADER_IMAGE: "${{ vars.REGISTRY }}/outscale/k8s-image-preloader:${{ github.sha }}"
- name: 🔎 Display snapshot ID
run: |
echo "snapshot: ${{ steps.snapshot.outputs.SNAPSHOT_ID}}"