Merge pull request #79 from sirius0xdev/feat/trade-dashboard-github-actions

feat(trade-dashboard): add GitHub Actions CI/CD + switch to ghcr.io
This commit is contained in:
sirius0xdev 2026-05-02 18:32:08 -04:00 committed by GitHub
commit 6afe8f41b7
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 53 additions and 1 deletions

52
.github/workflows/trade-dashboard.yml vendored Normal file
View file

@ -0,0 +1,52 @@
name: Build and Push Trade Dashboard
on:
push:
branches: [master]
paths:
- 'apps/base/customer1/trade-dashboard/**'
workflow_dispatch:
env:
REGISTRY: ghcr.io
IMAGE_NAME: ${{ github.repository_owner }}/trade-dashboard
permissions:
contents: read
packages: write
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to GHCR
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Extract metadata
id: meta
uses: docker/metadata-action@v5
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
tags: |
type=sha,prefix=
type=raw,value=latest,enable={{is_default_branch}}
- name: Build and push
uses: docker/build-push-action@v5
with:
context: apps/base/customer1/trade-dashboard
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
cache-from: type=gha
cache-to: type=gha,mode=max

View file

@ -22,7 +22,7 @@ spec:
terminationGracePeriodSeconds: 30 terminationGracePeriodSeconds: 30
containers: containers:
- name: dashboard - name: dashboard
image: us-central1-docker.pkg.dev/devops-lab-cluster/customer1/trade-dashboard:latest image: ghcr.io/sirius0xdev/trade-dashboard:latest
imagePullPolicy: Always imagePullPolicy: Always
ports: ports:
- containerPort: 8000 - containerPort: 8000