mirror of
https://github.com/TrezOne/docker-mods-uptime-kuma-timeout-fix.git
synced 2026-07-19 09:53:02 -04:00
Update BuildImage.yml
This commit is contained in:
@@ -19,6 +19,7 @@ jobs:
|
|||||||
if [ -z ${COMPOSE_TAG+x} ]; then COMPOSE_TAG=$(curl -sX GET "https://api.github.com/repos/linuxserver/docker-docker-compose/releases/latest" | awk '/tag_name/{print $4;exit}' FS='[""]'); fi
|
if [ -z ${COMPOSE_TAG+x} ]; then COMPOSE_TAG=$(curl -sX GET "https://api.github.com/repos/linuxserver/docker-docker-compose/releases/latest" | awk '/tag_name/{print $4;exit}' FS='[""]'); fi
|
||||||
if [ -z ${COMPOSE_ALPINE_TAG+x} ]; then COMPOSE_ALPINE_TAG=$(curl -sX GET "https://api.github.com/repos/linuxserver/docker-docker-compose/releases" | jq -r 'first(.[] | select(.prerelease==true)) | .tag_name'); fi
|
if [ -z ${COMPOSE_ALPINE_TAG+x} ]; then COMPOSE_ALPINE_TAG=$(curl -sX GET "https://api.github.com/repos/linuxserver/docker-docker-compose/releases" | jq -r 'first(.[] | select(.prerelease==true)) | .tag_name'); fi
|
||||||
COMPOSE_VERSION=$(echo "$COMPOSE_TAG" | sed 's|-ls.*||g')
|
COMPOSE_VERSION=$(echo "$COMPOSE_TAG" | sed 's|-ls.*||g')
|
||||||
|
echo "COMPOSE_VERSION=${COMPOSE_VERSION}" >> $GITHUB_ENV
|
||||||
COMPOSE_ALPINE_VERSION="$(echo ${COMPOSE_ALPINE_TAG} | sed 's|-ls.*||g' | sed 's|alpine-||g')"
|
COMPOSE_ALPINE_VERSION="$(echo ${COMPOSE_ALPINE_TAG} | sed 's|-ls.*||g' | sed 's|alpine-||g')"
|
||||||
if [ "$COMPOSE_VERSION" != "$COMPOSE_ALPINE_VERSION" ]; then echo "ubuntu and alpine versions are different; exiting!" && exit 1; else echo "ubuntu and alpine versions are the same, continuing with build"; fi
|
if [ "$COMPOSE_VERSION" != "$COMPOSE_ALPINE_VERSION" ]; then echo "ubuntu and alpine versions are different; exiting!" && exit 1; else echo "ubuntu and alpine versions are the same, continuing with build"; fi
|
||||||
# Build image
|
# Build image
|
||||||
@@ -28,8 +29,10 @@ jobs:
|
|||||||
if: ${{ github.ref == format('refs/heads/{0}-{1}', env.BASEIMAGE, env.MODNAME) }}
|
if: ${{ github.ref == format('refs/heads/{0}-{1}', env.BASEIMAGE, env.MODNAME) }}
|
||||||
run: |
|
run: |
|
||||||
docker tag ${{ github.sha }} ${ENDPOINT}:${BASEIMAGE}-${MODNAME}
|
docker tag ${{ github.sha }} ${ENDPOINT}:${BASEIMAGE}-${MODNAME}
|
||||||
|
docker tag ${{ github.sha }} ${ENDPOINT}:${BASEIMAGE}-${MODNAME}-${{ env.COMPOSE_VERSION }}-${{ github.sha }}
|
||||||
docker tag ${{ github.sha }} ${ENDPOINT}:${BASEIMAGE}-${MODNAME}-${{ github.sha }}
|
docker tag ${{ github.sha }} ${ENDPOINT}:${BASEIMAGE}-${MODNAME}-${{ github.sha }}
|
||||||
docker tag ${{ github.sha }} ghcr.io/${ENDPOINT}:${BASEIMAGE}-${MODNAME}
|
docker tag ${{ github.sha }} ghcr.io/${ENDPOINT}:${BASEIMAGE}-${MODNAME}
|
||||||
|
docker tag ${{ github.sha }} ghcr.io/${ENDPOINT}:${BASEIMAGE}-${MODNAME}-${{ env.COMPOSE_VERSION }}-${{ github.sha }}
|
||||||
docker tag ${{ github.sha }} ghcr.io/${ENDPOINT}:${BASEIMAGE}-${MODNAME}-${{ github.sha }}
|
docker tag ${{ github.sha }} ghcr.io/${ENDPOINT}:${BASEIMAGE}-${MODNAME}-${{ github.sha }}
|
||||||
|
|
||||||
- name: Credential check
|
- name: Credential check
|
||||||
@@ -54,6 +57,7 @@ jobs:
|
|||||||
- name: Push tags to GitHub Container Registry
|
- name: Push tags to GitHub Container Registry
|
||||||
if: ${{ github.ref == format('refs/heads/{0}-{1}', env.BASEIMAGE, env.MODNAME) && env.CR_USER && env.CR_PAT }}
|
if: ${{ github.ref == format('refs/heads/{0}-{1}', env.BASEIMAGE, env.MODNAME) && env.CR_USER && env.CR_PAT }}
|
||||||
run: |
|
run: |
|
||||||
|
docker push ghcr.io/${ENDPOINT}:${BASEIMAGE}-${MODNAME}-${{ env.COMPOSE_VERSION }}-${{ github.sha }}
|
||||||
docker push ghcr.io/${ENDPOINT}:${BASEIMAGE}-${MODNAME}-${{ github.sha }}
|
docker push ghcr.io/${ENDPOINT}:${BASEIMAGE}-${MODNAME}-${{ github.sha }}
|
||||||
docker push ghcr.io/${ENDPOINT}:${BASEIMAGE}-${MODNAME}
|
docker push ghcr.io/${ENDPOINT}:${BASEIMAGE}-${MODNAME}
|
||||||
|
|
||||||
@@ -65,5 +69,6 @@ jobs:
|
|||||||
- name: Push tags to DockerHub
|
- name: Push tags to DockerHub
|
||||||
if: ${{ github.ref == format('refs/heads/{0}-{1}', env.BASEIMAGE, env.MODNAME) && env.DOCKERUSER && env.DOCKERPASS }}
|
if: ${{ github.ref == format('refs/heads/{0}-{1}', env.BASEIMAGE, env.MODNAME) && env.DOCKERUSER && env.DOCKERPASS }}
|
||||||
run: |
|
run: |
|
||||||
|
docker push ${ENDPOINT}:${BASEIMAGE}-${MODNAME}-${{ env.COMPOSE_VERSION }}-${{ github.sha }}
|
||||||
docker push ${ENDPOINT}:${BASEIMAGE}-${MODNAME}-${{ github.sha }}
|
docker push ${ENDPOINT}:${BASEIMAGE}-${MODNAME}-${{ github.sha }}
|
||||||
docker push ${ENDPOINT}:${BASEIMAGE}-${MODNAME}
|
docker push ${ENDPOINT}:${BASEIMAGE}-${MODNAME}
|
||||||
|
|||||||
Reference in New Issue
Block a user