diff --git a/.gitea/workflows/build dev.yaml b/.gitea/workflows/build dev.yaml index 22e9a79..fe828d8 100644 --- a/.gitea/workflows/build dev.yaml +++ b/.gitea/workflows/build dev.yaml @@ -17,7 +17,7 @@ jobs: - name: Get Date and Build Number run: | - git fetch + git fetch --tags git tag DATE=$(date +'%Y.%m.%d') TAG_COUNT=$(git tag -l "${DATE}.*" | wc -l) @@ -54,13 +54,12 @@ jobs: uses: actions/download-artifact@v3 with: name: version - path: version.txt - name: Build docker run: | cd api echo "VERSION = \"$(cat version.txt)\"" > version.py - docker build --no-cache -t git.sh-edraft.de/sh-edraft.de/open-redirect-api:$(cat version.txt) . + docker build --no-cache -t git.sh-edraft.de/sh-edraft.de/open-redirect-api:$(cat ../version.txt) . - name: Login to registry git.sh-edraft.de uses: https://github.com/docker/login-action@v1 @@ -87,12 +86,11 @@ jobs: uses: actions/download-artifact@v3 with: name: version - path: version.txt - name: Build docker run: | cd api - docker build --no-cache -f dockerfile_redirector -t git.sh-edraft.de/sh-edraft.de/open-redirect-redirector:$(cat version.txt) . + docker build --no-cache -f dockerfile_redirector -t git.sh-edraft.de/sh-edraft.de/open-redirect-redirector:$(cat ../version.txt) . - name: Login to registry git.sh-edraft.de uses: https://github.com/docker/login-action@v1 @@ -119,7 +117,6 @@ jobs: uses: actions/download-artifact@v3 with: name: version - path: version.txt - name: Prepare web build run: | @@ -134,7 +131,7 @@ jobs: - name: Build docker run: | cd web - docker build --no-cache --build-arg VERSION=$(cat version.txt) -t git.sh-edraft.de/sh-edraft.de/open-redirect-web:$(cat version.txt) . + docker build --no-cache --build-arg VERSION=$(cat version.txt) -t git.sh-edraft.de/sh-edraft.de/open-redirect-web:$(cat ../version.txt) . - name: Login to registry git.sh-edraft.de uses: https://github.com/docker/login-action@v1 diff --git a/.gitea/workflows/build.yaml b/.gitea/workflows/build.yaml index 1f25681..7edb4eb 100644 --- a/.gitea/workflows/build.yaml +++ b/.gitea/workflows/build.yaml @@ -17,7 +17,7 @@ jobs: - name: Get Date and Build Number run: | - git fetch + git fetch --tags git tag DATE=$(date +'%Y.%m.%d') TAG_COUNT=$(git tag -l "${DATE}.*" | wc -l) @@ -59,7 +59,7 @@ jobs: run: | cd api echo "VERSION = \"$(cat version.txt)\"" > version.py - docker build --no-cache -t git.sh-edraft.de/sh-edraft.de/open-redirect-api:$(cat version.txt) . + docker build --no-cache -t git.sh-edraft.de/sh-edraft.de/open-redirect-api:$(cat ../version.txt) . - name: Login to registry git.sh-edraft.de uses: https://github.com/docker/login-action@v1 @@ -86,12 +86,11 @@ jobs: uses: actions/download-artifact@v3 with: name: version - path: version.txt - name: Build docker run: | cd api - docker build --no-cache -f dockerfile_redirector -t git.sh-edraft.de/sh-edraft.de/open-redirect-redirector:$(cat version.txt) . + docker build --no-cache -f dockerfile_redirector -t git.sh-edraft.de/sh-edraft.de/open-redirect-redirector:$(cat ../version.txt) . - name: Login to registry git.sh-edraft.de uses: https://github.com/docker/login-action@v1 @@ -118,7 +117,6 @@ jobs: uses: actions/download-artifact@v3 with: name: version - path: version.txt - name: Prepare web build run: | @@ -133,7 +131,7 @@ jobs: - name: Build docker run: | cd web - docker build --no-cache --build-arg VERSION=$(cat version.txt) -t git.sh-edraft.de/sh-edraft.de/open-redirect-web:$(cat version.txt) . + docker build --no-cache --build-arg VERSION=$(cat version.txt) -t git.sh-edraft.de/sh-edraft.de/open-redirect-web:$(cat ../version.txt) . - name: Login to registry git.sh-edraft.de uses: https://github.com/docker/login-action@v1