Skip to content

Commit

Permalink
v0.8.0 release build
Browse files Browse the repository at this point in the history
  • Loading branch information
Insprill committed Apr 20, 2024
1 parent 92a142b commit 99b39dd
Showing 1 changed file with 7 additions and 11 deletions.
18 changes: 7 additions & 11 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,6 @@ jobs:
- name: Checkout Repository
uses: actions/checkout@v4

- name: Set Docker push status
run: echo "DOCKER_PUSH=${{ !env.ACT && (github.ref == 'refs/heads/master' || startsWith(github.ref, 'refs/tags/v')) && github.event_name != 'pull_request' }}" >> $GITHUB_ENV

- name: Setup act
run: "sudo chown runner:docker /var/run/docker.sock"
if: ${{ env.ACT }}
Expand All @@ -28,14 +25,13 @@ jobs:

- name: Login to DockerHub
uses: docker/login-action@v3
if: ${{ env.DOCKER_PUSH == 'true' }}
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Docker Hub Description
if: false
uses: peter-evans/dockerhub-description@v3
if: ${{ env.DOCKER_PUSH == 'true' }}
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
Expand All @@ -45,18 +41,18 @@ jobs:
- name: Set Environment Variables
run: |
echo "IN_IS_GIT=true" >> .env
echo "IN_GIT_HASH=$(git rev-parse --short HEAD)" >> .env
echo "IN_GIT_DIRTY=$([[ -n $(git status --porcelain) ]] && echo true || echo false)" >> .env
echo "IN_GIT_TAG=$(git describe --tags --exact-match)" >> .env
echo "IN_GIT_TAGGED=$([[ -n $(git describe --tags --exact-match) ]] && echo true || echo false)" >> .env
echo "IN_GIT_HASH=ced8d640838231474f9a1630bd5790ee96bfa898" >> .env
echo "IN_GIT_DIRTY=false" >> .env
echo "IN_GIT_TAG=v0.8.0" >> .env
echo "IN_GIT_TAGGED=true" >> .env
echo "IN_GIT_REMOTE_URL=$(git remote get-url origin)" >> .env
- name: Build & Push
uses: docker/build-push-action@v5
with:
context: . # Required for running with act
push: ${{ env.DOCKER_PUSH == 'true' }}
tags: ${{ env.DOCKER_IMAGE }}:${{ startsWith(github.ref, 'refs/tags/v') && 'latest' || 'develop' }}
push: true
tags: insprill/intellectual:latest
platforms: ${{ env.DOCKER_PLATFORMS }}
cache-from: type=gha
cache-to: type=gha,mode=max

0 comments on commit 99b39dd

Please sign in to comment.