Skip to content

fix(ci): adds missing namespace #155

fix(ci): adds missing namespace

fix(ci): adds missing namespace #155

Workflow file for this run

name: "Deploy"
on:
push:
branches: ["main"]
workflow_dispatch:
env:
REGISTRY: ghcr.io
IMAGE_URL: ghcr.io/${{ github.repository }}:${{ github.sha }}
permissions:
id-token: write
contents: read
actions: read
jobs:
deploy:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- uses: actions/checkout@v4
- uses: oven-sh/setup-bun@v1
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Install dependencies
run: bun i --frozen-lockfile
- name: Populate latest workflows
run: bun run populate-workflows
- name: Login to ghcr.io
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build image and push to registry
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile
platforms: linux/arm64
push: true
tags: ${{ env.IMAGE_URL }}
- name: Join our Tailnet
uses: tailscale/github-action@v2
with:
oauth-client-id: ${{ secrets.TAILSCALE_OAUTH_CLIENT_ID }}
oauth-secret: ${{ secrets.TAILSCALE_OAUTH_SECRET }}
tags: ${{ secrets.TAILSCALE_TAGS }}
- name: Set the Kubernetes context
uses: azure/k8s-set-context@v4
with:
method: service-account
k8s-url: ${{ secrets.KUBERNETES_URL }}
k8s-secret: ${{ secrets.KUBERNETES_SECRET }}
- name: Deploy to the Kubernetes cluster
uses: azure/k8s-deploy@v5
with:
namespace: getactions
manifests: |
kubernetes/deployment.yaml
kubernetes/ingress.yaml
kubernetes/service.yaml
images: |
${{ env.IMAGE_URL }}