Skip to content

Adjusted typo.

Adjusted typo. #19

name: deploy webapp
concurrency: deploy
on:
workflow_dispatch:
push:
branches:
- main
paths:
- frontend/**
- .github/workflows/deploy-webapp.yaml
jobs:
build:
name: Deploy frontend
runs-on: "ubuntu-24.04"
environment: deploy
defaults:
run:
shell: bash -l {0}
steps:
- uses: actions/checkout@v4
- name: "Unlock git-crypt secrets"
uses: sliteteam/github-action-git-crypt-unlock@f99c0c6b60bb7ec30dcec033a8f0a3b3d48f21e1
env:
GIT_CRYPT_KEY: ${{ secrets.GIT_CRYPT_KEY }}
- name: Setup Kubernetes configuration
uses: azure/k8s-set-context@v3
with:
method: kubeconfig
kubeconfig: gfts-track-reconstruction/jupyterhub/secrets/kubeconfig.yaml
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to Docker
uses: azure/docker-login@v1
with:
login-server: c63eqfuv.c1.gra9.container-registry.ovh.net
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Extract metadata for Docker
id: meta
uses: docker/metadata-action@v5
with:
images: c63eqfuv.c1.gra9.container-registry.ovh.net/gfts/webapp
tags: |
type=ref,event=branch
type=sha,format=short
latest
- name: Build and push Docker image
uses: docker/build-push-action@v5
with:
context: ./webapp
file: ./webapp/deploy/Dockerfile
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
- name: Setup Helm
uses: azure/setup-helm@v3
with:
version: 'latest'
- name: Update Helm dependencies
run: |
helm dependency update ./webapp/deploy/helm
- name: Deploy to Kubernetes
run: |
helm upgrade --install \
--namespace webapp \
webapp \
./webapp/deploy/helm \
--set image.repository=c63eqfuv.c1.gra9.container-registry.ovh.net/gfts/webapp \
--set image.tag=$(echo "${{ steps.meta.outputs.tags }}" | head -n 1)
env:
KUBECONFIG: ${{ github.workspace }}/.kube/config