Added proper CI
All checks were successful
OpenClimb Docker Deploy / build-and-push (pull_request) Successful in 2m3s

This commit is contained in:
2025-09-28 23:29:44 -06:00
parent 6e490d1598
commit f7f1fba9aa
11 changed files with 348 additions and 3 deletions

43
.github/workflows/deploy.yml vendored Normal file
View File

@@ -0,0 +1,43 @@
name: OpenClimb Docker Deploy
on:
push:
branches: [main]
paths:
- "sync/**"
- ".github/workflows/deploy.yml"
pull_request:
branches: [main]
paths:
- "sync/**"
- ".github/workflows/deploy.yml"
jobs:
build-and-push:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Login to Container Registry
uses: docker/login-action@v2
with:
registry: ${{ secrets.REPO_HOST }}
username: ${{ github.repository_owner }}
password: ${{ secrets.DEPLOY_TOKEN }}
- name: Build and push sync-server
uses: docker/build-push-action@v4
with:
context: ./sync
file: ./sync/Dockerfile
platforms: linux/amd64
push: true
tags: |
${{ secrets.REPO_HOST }}/${{ github.repository_owner }}/openclimb-sync-server:${{ github.sha }}
${{ secrets.REPO_HOST }}/${{ github.repository_owner }}/openclimb-sync-server:latest