1
0
mirror of https://github.com/XFox111/easylogon-web.git synced 2026-07-02 19:52:45 +03:00
Files
easylogon-web/.github/workflows/ci.yml
T

56 lines
1.4 KiB
YAML

name: "CI pipeline"
on:
release:
types:
- published
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
permissions:
packages: write
steps:
- uses: actions/checkout@v6
- name: Update the version
if: startsWith(github.ref, 'refs/tags/')
run: |
sed -i 's|"version": "0.0.0"|"version": "${{ github.ref_name }}"|' package.json
- uses: docker/metadata-action@v6
id: meta
with:
images: |
${{ github.repository }}
ghcr.io/${{ github.repository }}
tags: |
latest
${{ github.ref_name }}
- name: "Login to Docker Hub"
uses: docker/login-action@v4
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: "Login to GitHub Container Registry"
uses: docker/login-action@v4
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- uses: docker/build-push-action@v7
with:
context: .
build-args: |
SIGNALR_URL=https://ezlog.app/api/comms
ENDPOINT_URL=https://ezlog.app/api/send
COMMIT=${{ github.sha }}
push: true
tags: ${{ steps.meta.outputs.tags }}