diff options
| author | cyBerta <cyberta@riseup.net> | 2024-07-16 12:47:42 +0200 |
|---|---|---|
| committer | cyBerta <cyberta@riseup.net> | 2024-07-16 14:40:59 +0200 |
| commit | 9078a324b7bd5507d1151375ba82101b217b28bc (patch) | |
| tree | 9947d004ce6ac4c8805af24564912df218c28033 | |
| parent | 95267dc33bd0e5cc6f27728525572c4081a0ba1d (diff) | |
ensure re-build is actually triggered
| -rwxr-xr-x | .gitlab/build.sh | 7 | ||||
| -rw-r--r-- | docker/android-ndk/Dockerfile | 1 |
2 files changed, 4 insertions, 4 deletions
diff --git a/.gitlab/build.sh b/.gitlab/build.sh index 6f989001..18dc6224 100755 --- a/.gitlab/build.sh +++ b/.gitlab/build.sh @@ -1,15 +1,14 @@ #!/bin/bash +set -x # # Build script for the gitlab ci. # # usage: build.sh DIR [TAG] # -# Will run docker build in DIR with DIR/Dockerfile or -# DIR/TAG.dockerfile if TAG is given. +# Will run docker build in DIR with DIR/Dockerfile # # Assumes CI specific environment variables to be set: # CI_REGISTRY_IMAGE -# LAST_COMMIT (fetched from the gitlab api in before_script hook) # DIR=$1 @@ -22,7 +21,7 @@ function quit { exit 1 } -if git diff "$LAST_COMMIT" HEAD --name-only | egrep "($DOCKERFILE|^.gitlab)"; then +if git show HEAD~1 --name-only | grep "$DOCKERFILE"; then docker login -u gitlab-ci-token -p "$CI_JOB_TOKEN" "$CI_REGISTRY" || quit docker build -t "$TARGET" -f "$DOCKERFILE" docker/ || quit docker push "$TARGET" || quit diff --git a/docker/android-ndk/Dockerfile b/docker/android-ndk/Dockerfile index 8b35f795..e226959a 100644 --- a/docker/android-ndk/Dockerfile +++ b/docker/android-ndk/Dockerfile @@ -68,3 +68,4 @@ RUN curl -L -o "go.tar.gz" "https://golang.org/dl/${GO_VERSION}.tar.gz"; \ echo "${EXPECTED_FP} go.tar.gz" | sha256sum -c - && \ tar -C /usr/local -xzf go.tar.gz && \ rm go.tar.gz \ + |
