diff --git a/.github/workflows/docker-image-push.yml b/.github/workflows/docker-image-push.yml index 91f744d..3f80abb 100644 --- a/.github/workflows/docker-image-push.yml +++ b/.github/workflows/docker-image-push.yml @@ -13,8 +13,6 @@ jobs: runs-on: ubuntu-20.04 strategy: fail-fast: false - matrix: - dockerfile: [Dockerfile] steps: - name: Checkout uses: actions/checkout@v1 @@ -47,5 +45,4 @@ jobs: env: PLATFORMS: linux/amd64,linux/arm64/v8,linux/arm/v7 DOCKER_REPOSITORY: thelounge/thelounge - DOCKERFILE: ${{ matrix.dockerfile }} run: ./scripts/build-and-push.sh diff --git a/.github/workflows/docker-image-test.yml b/.github/workflows/docker-image-test.yml index 7c1991f..2a1c928 100644 --- a/.github/workflows/docker-image-test.yml +++ b/.github/workflows/docker-image-test.yml @@ -46,7 +46,7 @@ jobs: exit $s - name: Check for no ERROR logs - run: docker logs thelounge | grep "\[ERROR\]" && exit 1 || exit 0 + run: docker logs thelounge 2>&1 | grep -vz "\[ERROR\]" - name: Check for config.js to be created in the mounted host system directory run: stat "${mount_dir}/config.js" diff --git a/Dockerfile b/Dockerfile index f2c39b7..6d64f35 100644 --- a/Dockerfile +++ b/Dockerfile @@ -16,7 +16,9 @@ COPY docker-entrypoint.sh /usr/local/bin/docker-entrypoint.sh # Install thelounge. ARG THELOUNGE_VERSION=4.3.1 -RUN apk --update --no-cache --virtual build-deps add git && \ +RUN apk --update --no-cache --virtual build-deps add python3 build-base git && \ + ln -sf python3 /usr/bin/python && \ yarn --non-interactive --frozen-lockfile global add thelounge@${THELOUNGE_VERSION} && \ yarn --non-interactive cache clean && \ - apk del build-deps + apk del --purge build-deps && \ + rm -rf /root/.cache /tmp /usr/bin/python diff --git a/scripts/build-and-push.sh b/scripts/build-and-push.sh index 1f8057a..d0ba794 100755 --- a/scripts/build-and-push.sh +++ b/scripts/build-and-push.sh @@ -19,5 +19,5 @@ docker buildx build \ --platform "${PLATFORMS}" \ --tag "${DOCKER_REPOSITORY}:${TAG}" \ "${EXTRA_ARG[@]}" \ - --file "${DOCKERFILE}" \ + --file Dockerfile \ .