generated from nathanwoodburn/python-webserver-template
fix: remove test runner script
This commit is contained in:
parent
bc3fc2862e
commit
a26eecf59e
@ -1,54 +0,0 @@
|
|||||||
name: Build Docker fast
|
|
||||||
run-name: Build Docker Images fast
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
BuildImage:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Checkout
|
|
||||||
uses: actions/checkout@v3
|
|
||||||
|
|
||||||
- name: Set up Docker Buildx
|
|
||||||
uses: docker/setup-buildx-action@v2
|
|
||||||
|
|
||||||
- name: Login to Docker Registry
|
|
||||||
uses: docker/login-action@v2
|
|
||||||
with:
|
|
||||||
registry: git.woodburn.au
|
|
||||||
username: nathanwoodburn
|
|
||||||
password: ${{ secrets.DOCKERGIT_TOKEN }}
|
|
||||||
|
|
||||||
- name: Extract metadata
|
|
||||||
id: meta
|
|
||||||
run: |
|
|
||||||
echo "branch=${GITHUB_HEAD_REF:-${GITHUB_REF#refs/heads/}}" >> $GITHUB_OUTPUT
|
|
||||||
tag=${GITHUB_HEAD_REF:-${GITHUB_REF#refs/heads/}}
|
|
||||||
tag=${tag//\//-}
|
|
||||||
echo "tag=$tag" >> $GITHUB_OUTPUT
|
|
||||||
tag_num=${GITHUB_RUN_NUMBER}
|
|
||||||
echo "tag_num=$tag_num" >> $GITHUB_OUTPUT
|
|
||||||
|
|
||||||
if [[ "$tag" == "main" ]]; then
|
|
||||||
echo "final_tag=latest" >> $GITHUB_OUTPUT
|
|
||||||
else
|
|
||||||
echo "final_tag=${tag}-${tag_num}" >> $GITHUB_OUTPUT
|
|
||||||
fi
|
|
||||||
|
|
||||||
repo=$GITHUB_REPOSITORY
|
|
||||||
repo=${repo#*/}
|
|
||||||
repo=$(echo $repo | tr '[:upper:]' '[:lower:]')
|
|
||||||
echo "repo=$repo" >> $GITHUB_OUTPUT
|
|
||||||
|
|
||||||
- name: Build and push
|
|
||||||
uses: docker/build-push-action@v4
|
|
||||||
with:
|
|
||||||
context: .
|
|
||||||
push: true
|
|
||||||
tags: |
|
|
||||||
git.woodburn.au/nathanwoodburn/${{ steps.meta.outputs.repo }}:${{ steps.meta.outputs.final_tag }}
|
|
||||||
git.woodburn.au/nathanwoodburn/${{ steps.meta.outputs.repo }}:${{ steps.meta.outputs.tag_num }}
|
|
||||||
git.woodburn.au/nathanwoodburn/${{ steps.meta.outputs.repo }}:${{ steps.meta.outputs.tag }}
|
|
||||||
cache-from: type=gha
|
|
||||||
cache-to: type=gha,mode=max
|
|
Loading…
Reference in New Issue
Block a user