From 278abf1b868d12b3d6655f8c18020889c7c7eb21 Mon Sep 17 00:00:00 2001 From: Thephaseless Date: Sun, 24 Nov 2024 22:13:47 +0000 Subject: [PATCH] fix dockerfile and add arm for testing --- .github/workflows/docker-publish.yml | 13 ++++++------- Dockerfile | 12 +++++------- 2 files changed, 11 insertions(+), 14 deletions(-) diff --git a/.github/workflows/docker-publish.yml b/.github/workflows/docker-publish.yml index e5d64ed..4004128 100644 --- a/.github/workflows/docker-publish.yml +++ b/.github/workflows/docker-publish.yml @@ -23,6 +23,12 @@ env: jobs: test: + strategy: + fail-fast: false + matrix: + platform: + - linux/amd64 + - linux/arm64 runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 @@ -67,13 +73,6 @@ jobs: # with sigstore/fulcio when running outside of PRs. id-token: write - strategy: - fail-fast: false - matrix: - platform: - - linux/amd64 - - linux/arm64 - steps: - name: Checkout repository uses: actions/checkout@v4 diff --git a/Dockerfile b/Dockerfile index 79df348..097cd20 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM python:3.12-alpine +FROM python:3.12-slim # Inspired by https://github.com/Hudrolax/uc-docker-alpine/ @@ -16,14 +16,12 @@ ENV \ POETRY_VIRTUALENVS_IN_PROJECT=true \ DISPLAY=:0 -# Install build dependencies -RUN apk update && apk upgrade && apk add --no-cache \ - xvfb \ - chromium - WORKDIR /app EXPOSE 8191 - +ADD https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb ./ +RUN apt update &&\ + apt install -y xvfb scrot python3-tk curl ./google-chrome-stable_current_amd64.deb &&\ + rm ./google-chrome-stable_current_amd64.deb RUN curl -sSL https://install.python-poetry.org | python3 - ENV PATH="${HOME}/.local/bin:$PATH"