Skip to content

Commit

Permalink
Merge pull request #526 from karrioapi/automated-build
Browse files Browse the repository at this point in the history
Automated build
  • Loading branch information
danh91 authored Mar 7, 2024
2 parents 4008ed9 + 70f5d43 commit 69cfd34
Show file tree
Hide file tree
Showing 2 changed files with 60 additions and 22 deletions.
60 changes: 60 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
name: karrio-build

on:
push:
branches: [ "main" ]

env:
VERSION: $(head -1 ./apps/api/karrio/server/VERSION)
NEW_VERSION: $(git diff --quiet ${{ github.event.before }} ${{ github.sha }} apps/api/karrio/server/VERSION)

jobs:
server-build:

runs-on: ubuntu-latest
permissions:
contents: read
packages: write
id-token: write

steps:
- uses: actions/checkout@v3
- run: |
echo 'Checking variables... ${{ env.NEW_VERSION != '' }} | ${{ env.NEW_VERSION }} | ${{ env.VERSION }}'
- name: Build karrio server image
if: ${{ env.NEW_VERSION != '' }}
run: |
echo 'Building karrio server:${{ env.VERSION }}...'
# ./bin/build-server-image-from-source ${{ env.VERSION }}
- name: Push karrio server image
if: ${{ env.NEW_VERSION != '' }}
run: |
echo 'Pushing karrio server:${{ env.VERSION }}...'
docker login -u ${{ secrets.DOCKER_USERNAME }} -p ${{ secrets.DOCKER_PASSWORD }}
# docker push karrio/karrio-server:${{ env.VERSION }}
# dashboard-build:

# runs-on: ubuntu-latest
# permissions:
# contents: read
# packages: write
# id-token: write

# steps:
# - uses: actions/checkout@v3

# - name: Build karrio dashboard image
# if: ${{ env.NEW_VERSION != '' }}
# run: |
# echo 'Building karrio dashboard:${{ env.VERSION }}...'
# # ./bin/build-dashboard-from-source ${{ env.VERSION }}

# - name: Push karrio dashboard image
# if: ${{ env.NEW_VERSION != '' }}
# run: |
# echo 'Pushing karrio dashboard:${{ env.VERSION }}...'
# docker login -u ${{ secrets.DOCKER_USERNAME }} -p ${{ secrets.DOCKER_PASSWORD }}
# # docker push karrio/karrio-dashboard:${{ env.VERSION }}
22 changes: 0 additions & 22 deletions .github/workflows/codesee-arch-diagram.yml

This file was deleted.

0 comments on commit 69cfd34

Please sign in to comment.