Skip to content

Commit

Permalink
Use short commit sha to avoid horrible tags
Browse files Browse the repository at this point in the history
  • Loading branch information
thespad committed May 14, 2024
1 parent 6f0e6a9 commit 908ef30
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/external_trigger.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
echo "**** External trigger running off of testing branch. To disable this trigger, set a Github secret named \"PAUSE_EXTERNAL_TRIGGER_NZBGET_TESTING\". ****"
echo "External trigger running off of testing branch. To disable this trigger, set a Github secret named \`PAUSE_EXTERNAL_TRIGGER_NZBGET_TESTING\`" >> $GITHUB_STEP_SUMMARY
echo "**** Retrieving external version ****"
EXT_RELEASE=$(curl -u "${{ secrets.CR_USER }}:${{ secrets.CR_PAT }}" -sX GET "https://api.github.com/repos/nzbgetcom/nzbget/git/matching-refs/tags/testing" | jq -r '. | .[].object.sha')
EXT_RELEASE=$(curl -u "${{ secrets.CR_USER }}:${{ secrets.CR_PAT }}" -sX GET "https://api.github.com/repos/nzbgetcom/nzbget/git/matching-refs/tags/testing" | jq -r '. | .[].object.sha[:7]')
if [ -z "${EXT_RELEASE}" ] || [ "${EXT_RELEASE}" == "null" ]; then
echo "**** Can't retrieve external version, exiting ****"
FAILURE_REASON="Can't retrieve external version for nzbget branch testing"
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ RUN \
echo "**** build nzbget ****" && \
if [ -z ${NZBGET_RELEASE+x} ]; then \
NZBGET_RELEASE=$(curl -sX GET "https://api.github.com/repos/nzbgetcom/nzbget/git/matching-refs/tags/testing" \
| jq -r '.[].object.sha'); \
| jq -r '.[].object.sha[:7]'); \
fi && \
mkdir -p /nzbget && \
git clone https://github.com/nzbgetcom/nzbget.git nzbget && \
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.aarch64
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ RUN \
echo "**** build nzbget ****" && \
if [ -z ${NZBGET_RELEASE+x} ]; then \
NZBGET_RELEASE=$(curl -sX GET "https://api.github.com/repos/nzbgetcom/nzbget/git/matching-refs/tags/testing" \
| jq -r '.[].object.sha'); \
| jq -r '.[].object.sha[:7]'); \
fi && \
mkdir -p /nzbget && \
git clone https://github.com/nzbgetcom/nzbget.git nzbget && \
Expand Down
2 changes: 1 addition & 1 deletion Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ pipeline {
GITLAB_NAMESPACE=credentials('gitlab-namespace-id')
DOCKERHUB_TOKEN=credentials('docker-hub-ci-pat')
JSON_URL = 'https://api.github.com/repos/nzbgetcom/nzbget/git/matching-refs/tags/testing'
JSON_PATH = '.[].object.sha'
JSON_PATH = '.[].object.sha[:7]'
BUILD_VERSION_ARG = 'NZBGET_RELEASE'
LS_USER = 'linuxserver'
LS_REPO = 'docker-nzbget'
Expand Down
2 changes: 1 addition & 1 deletion jenkins-vars.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ release_tag: testing
ls_branch: testing
repo_vars:
- JSON_URL = 'https://api.github.com/repos/nzbgetcom/nzbget/git/matching-refs/tags/testing'
- JSON_PATH = '.[].object.sha'
- JSON_PATH = '.[].object.sha[:7]'
- BUILD_VERSION_ARG = 'NZBGET_RELEASE'
- LS_USER = 'linuxserver'
- LS_REPO = 'docker-nzbget'
Expand Down

0 comments on commit 908ef30

Please sign in to comment.