Compare commits

...

2 commits
0.1.8 ... main

Author SHA1 Message Date
025ff6a42f Fix indenting
All checks were successful
Run Tests on Code / test (push) Successful in 7m35s
2024-01-01 20:51:22 +00:00
a54baf4b3d Setup registry for buildx + Update CI to current defaults
Some checks are pending
Run Tests on Code / test (push) Waiting to run
2024-01-01 20:42:26 +00:00

View file

@ -5,7 +5,7 @@ on:
push: push:
tags: tags:
- '[0-9]+.[0-9]+.[0-9]+' - '[0-9]+.[0-9]+.[0-9]+'
- '[0-9]+.[0-9]+.[0-9]+rc[0-9]+' - '[0-9]+.[0-9]+.[0-9]+-rc.[0-9]+'
jobs: jobs:
test: test:
runs-on: docker runs-on: docker
@ -37,10 +37,10 @@ jobs:
run: | run: |
VERSION=$(cat package.json | grep "version" | sed 's/.*://' | tr -d , | tr -d \" | tr -d " " ) VERSION=$(cat package.json | grep "version" | sed 's/.*://' | tr -d , | tr -d \" | tr -d " " )
if test $VERSION != "${{ github.ref_name }}"; then if test $VERSION != "${{ github.ref_name }}"; then
echo "Expected Version is: '${{ github.ref_name }}' actual Version is: '$VERSION'"; echo "Expected Version is: '${{ github.ref_name }}' actual Version is: '$VERSION'";
exit 1 exit 1
else else
echo "Version is: '$VERSION'"; echo "Version is: '$VERSION'";
fi fi
build: build:
@ -51,6 +51,10 @@ jobs:
- -
name: Set up Docker Buildx name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3 uses: docker/setup-buildx-action@v3
with:
config-inline: |
[registry."docker.io"]
mirrors = ["https://docker-cache.neshweb.net"]
- -
name: Login to Docker Hub name: Login to Docker Hub
uses: docker/login-action@v3 uses: docker/login-action@v3
@ -58,12 +62,22 @@ jobs:
registry: forgejo.neshweb.net registry: forgejo.neshweb.net
username: ${{ secrets.FORGEJO_USERNAME }} username: ${{ secrets.FORGEJO_USERNAME }}
password: ${{ secrets.FORGEJO_TOKEN }} password: ${{ secrets.FORGEJO_TOKEN }}
-
name: Determine Docker tags
id: tags
run: |
if echo ${{ github.ref_name }} | grep -qi '\-rc' ; then
echo latest=forgejo.neshweb.net/neshweb-sites/${{ github.event.repository.name }}:preview >> $GITHUB_OUTPUT;
else
echo latest=forgejo.neshweb.net/neshweb-sites/${{ github.event.repository.name }}:latest >> $GITHUB_OUTPUT;
fi
echo version=forgejo.neshweb.net/neshweb-sites/${{ github.event.repository.name }}:${{ github.ref_name }} >> $GITHUB_OUTPUT;
- -
name: Push to Package Registry name: Push to Package Registry
uses: docker/build-push-action@v5 uses: docker/build-push-action@v5
with: with:
push: true push: true
tags: forgejo.neshweb.net/neshweb-sites/readyornot:${{ github.ref_name }}, forgejo.neshweb.net/neshweb-sites/readyornot:latest tags: ${{ steps.tags.outputs.version }}, ${{ steps.tags.outputs.latest }}
release: release:
needs: build needs: build