From 6879e4d2bf03ecdf8868a36a209a6f84a1014b55 Mon Sep 17 00:00:00 2001 From: Jose Henrique Date: Sat, 16 Aug 2025 22:30:04 -0300 Subject: [PATCH] pipe --- .gitea/workflows/haven-notify.yaml | 57 ++++++++++++++++-------------- 1 file changed, 30 insertions(+), 27 deletions(-) diff --git a/.gitea/workflows/haven-notify.yaml b/.gitea/workflows/haven-notify.yaml index aca664d..097ef1b 100644 --- a/.gitea/workflows/haven-notify.yaml +++ b/.gitea/workflows/haven-notify.yaml @@ -16,37 +16,37 @@ env: KUBE_CONFIG: ${{ secrets.KUBE_CONFIG }} jobs: - build_haven_notify: - name: Build Haven Notify Image (arm64) - runs-on: ubuntu-arm64 + # build_haven_notify: + # name: Build Haven Notify Image (arm64) + # runs-on: ubuntu-arm64 - steps: - - name: Check out repository - uses: actions/checkout@v2 + # steps: + # - name: Check out repository + # uses: actions/checkout@v2 - - name: Install Docker - run: | - apt-get update - apt-get install -y docker.io + # - name: Install Docker + # run: | + # apt-get update + # apt-get install -y docker.io - - name: Log in to Container Registry - run: | - echo "${{ secrets.REGISTRY_PASSWORD }}" \ - | docker login "${{ env.REGISTRY_HOST }}" \ - -u "${{ env.REGISTRY_USERNAME }}" \ - --password-stdin + # - name: Log in to Container Registry + # run: | + # echo "${{ secrets.REGISTRY_PASSWORD }}" \ + # | docker login "${{ env.REGISTRY_HOST }}" \ + # -u "${{ env.REGISTRY_USERNAME }}" \ + # --password-stdin - - name: Build and Push Image - run: | - TAG=latest + # - name: Build and Push Image + # run: | + # TAG=latest - cd haven-notify + # cd haven-notify - docker build \ - -t "${{ env.IMAGE_NOTIFY }}:${TAG}" \ - -f Dockerfile . + # docker build \ + # -t "${{ env.IMAGE_NOTIFY }}:${TAG}" \ + # -f Dockerfile . - docker push "${{ env.IMAGE_NOTIFY }}:${TAG}" + # docker push "${{ env.IMAGE_NOTIFY }}:${TAG}" build_haven_notify_amd64: name: Build Haven Notify Image (amd64) @@ -82,8 +82,8 @@ jobs: deploy_haven_notify: name: Deploy Haven Notify - runs-on: ubuntu-arm64 - needs: build_haven_notify + runs-on: ubuntu-amd64 + needs: build_haven_notify_amd64 steps: - name: Check KUBE_CONFIG validity run: | @@ -99,7 +99,7 @@ jobs: run: | apt-get update -y apt-get install -y curl - curl -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/arm64/kubectl" + curl -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl" install -m 0755 kubectl /usr/local/bin/kubectl kubectl version --client @@ -112,12 +112,15 @@ jobs: - name: Test connection to cluster run: | + cd haven-notify/deploy kubectl --kubeconfig=kubeconfig.yaml cluster-info - name: Apply haven-notify deployment run: | + cd haven-notify/deploy kubectl --kubeconfig=kubeconfig.yaml apply -f haven-notify.yaml - name: Rollout restart haven-notify run: | + cd haven-notify/deploy kubectl --kubeconfig=kubeconfig.yaml rollout restart deployment/haven-notify