From 1c1ad3a716f8a3013b1f4f7a02a7f143d5da4ac1 Mon Sep 17 00:00:00 2001 From: Shish Date: Mon, 26 Jun 2023 22:35:05 +0100 Subject: [PATCH 1/4] s/debian:stable/debian:bullseye/ --- Dockerfile | 8 ++++---- core/sys_config.php | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Dockerfile b/Dockerfile index 61ccbab6..cb6c518f 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,6 @@ # "Build" shimmie (composer install - done in its own stage so that we don't # need to include all the composer fluff in the final image) -FROM debian:stable AS app +FROM debian:bullseye AS app RUN apt update && apt install -y composer php7.4-gd php7.4-dom php7.4-sqlite3 php-xdebug imagemagick COPY composer.json composer.lock /app/ WORKDIR /app @@ -10,7 +10,7 @@ COPY . /app/ # Tests in their own image. Really we should inherit from app and then # `composer install` phpunit on top of that; but for some reason # `composer install --no-dev && composer install` doesn't install dev -FROM debian:stable AS tests +FROM debian:bullseye AS tests RUN apt update && apt install -y composer php7.4-gd php7.4-dom php7.4-sqlite3 php-xdebug imagemagick COPY composer.json composer.lock /app/ WORKDIR /app @@ -25,7 +25,7 @@ RUN [ $RUN_TESTS = false ] || (\ echo '=== Cleaning ===' && rm -rf data) # Build su-exec so that our final image can be nicer -FROM debian:stable AS suexec +FROM debian:bullseye AS suexec RUN apt-get update && apt-get install -y --no-install-recommends gcc libc-dev curl RUN curl -k -o /usr/local/bin/su-exec.c https://raw.githubusercontent.com/ncopa/su-exec/master/su-exec.c; \ gcc -Wall /usr/local/bin/su-exec.c -o/usr/local/bin/su-exec; \ @@ -33,7 +33,7 @@ RUN curl -k -o /usr/local/bin/su-exec.c https://raw.githubusercontent.com/ncopa chmod 0755 /usr/local/bin/su-exec; # Actually run shimmie -FROM debian:stable +FROM debian:bullseye EXPOSE 8000 HEALTHCHECK --interval=1m --timeout=3s CMD curl --fail http://127.0.0.1:8000/ || exit 1 ENV UID=1000 \ diff --git a/core/sys_config.php b/core/sys_config.php index 5511605e..12bef372 100644 --- a/core/sys_config.php +++ b/core/sys_config.php @@ -28,7 +28,7 @@ _d("DEBUG", false); // boolean print various debugging details _d("COOKIE_PREFIX", 'shm'); // string if you run multiple galleries with non-shared logins, give them different prefixes _d("SPEED_HAX", false); // boolean do some questionable things in the name of performance _d("WH_SPLITS", 1); // int how many levels of subfolders to put in the warehouse -_d("VERSION", "2.9.2$_g"); // string shimmie version +_d("VERSION", "2.9.3$_g"); // string shimmie version _d("TIMEZONE", null); // string timezone _d("EXTRA_EXTS", ""); // string optional extra extensions _d("BASE_HREF", null); // string force a specific base URL (default is auto-detect) From 9025ab36eadfc47dc8ed5eeb398f191903c2b781 Mon Sep 17 00:00:00 2001 From: Shish Date: Mon, 26 Jun 2023 23:03:46 +0100 Subject: [PATCH 2/4] push tags --- .github/workflows/publish.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 89f1fb79..24b706a7 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -22,3 +22,4 @@ jobs: password: ${{ secrets.DOCKER_PASSWORD }} cache: ${{ github.event_name != 'schedule' }} buildoptions: "--build-arg RUN_TESTS=false" + tag_semver: true From 9af4d8e5560527079ae79506a0b79c8590d1cbe5 Mon Sep 17 00:00:00 2001 From: Shish Date: Mon, 26 Jun 2023 23:15:03 +0100 Subject: [PATCH 3/4] trigger by tag push --- .github/workflows/publish.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 24b706a7..b9426e86 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -6,6 +6,9 @@ on: branches: master types: completed workflow_dispatch: + push: + tags: + - 'v*' jobs: publish: From 2ce58632bb2ac8451677de3d1dcaca51dc68af7e Mon Sep 17 00:00:00 2001 From: Shish Date: Mon, 26 Jun 2023 23:16:53 +0100 Subject: [PATCH 4/4] push too --- .github/workflows/publish.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index b9426e86..eed6ac84 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -14,7 +14,7 @@ jobs: publish: name: Publish runs-on: ubuntu-latest - if: ${{ github.event.workflow_run.conclusion == 'success' || github.event_name == 'workflow_dispatch' }} + if: ${{ github.event.workflow_run.conclusion == 'success' || github.event_name == 'workflow_dispatch' || github.event_name == 'push' }} steps: - uses: actions/checkout@master - name: Publish to Registry