Skip to content

Commit

Permalink
Merge pull request #3 from hathitrust/debug_build
Browse files Browse the repository at this point in the history
Checkout desired ref before rev-parse
  • Loading branch information
aelkiss authored Apr 22, 2022
2 parents b9e9a4e + 4d32c4b commit a537d87
Showing 1 changed file with 7 additions and 9 deletions.
16 changes: 7 additions & 9 deletions build/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,14 @@ inputs:
default: ghcr.io
registry_username:
description: >-
Username for logging in to registry. For GHCR (and by default), set to github.actor.
Username for logging in to registry. For GHCR (and by default),
set to github.actor.
default: ${{ github.actor }}
registry_token:
description: >-
Token for logging in to registry. For GHCR, use secrets.GITHUB_TOKEN.
required: true
Token for logging in to registry. For GHCR (and by default),
set to github.token.
default: ${{ github.token }}
build-args:
description: >-
Arguments to pass to docker build
Expand All @@ -40,6 +42,8 @@ runs:
steps:
- name: Clone latest repository
uses: actions/checkout@v3
with:
ref: ${{ inputs.tag }}

- name: Find commit for tag
id: tag_check
Expand Down Expand Up @@ -84,12 +88,6 @@ runs:
core.setOutput('latest_tag','')
}
- name: Check out at given revision
if: ${{ steps.image_check.outputs.image_exists != 'true' }}
uses: actions/checkout@v3
with:
ref: ${{ inputs.tag }}

- name: Build image and push to GHCR
if: ${{ steps.image_check.outputs.image_exists != 'true' }}
uses: docker/build-push-action@v2
Expand Down

0 comments on commit a537d87

Please sign in to comment.