From 75f326e58c9159568233667021b6538df8504778 Mon Sep 17 00:00:00 2001 From: nashaofu Date: Wed, 1 May 2024 10:41:19 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8DCI=E6=8A=A5=E9=94=99?= =?UTF-8?q?=20(#39)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 0.2.0 --- .github/workflows/docker-publish.yml | 9 +-------- .github/workflows/napi.yml | 2 ++ docker/alpine.Dockerfile | 4 ++-- docker/debian.Dockerfile | 4 ++-- 4 files changed, 7 insertions(+), 12 deletions(-) diff --git a/.github/workflows/docker-publish.yml b/.github/workflows/docker-publish.yml index 9db548b..ba747a4 100644 --- a/.github/workflows/docker-publish.yml +++ b/.github/workflows/docker-publish.yml @@ -2,12 +2,6 @@ name: docker-publish on: workflow_dispatch: # 手动触发 - push: - branches: ["master"] - # Publish semver tags as releases. - tags: ["v*.*.*"] - pull_request: - branches: ["master"] concurrency: group: ${{ github.workflow }}-${{ github.ref }} @@ -45,7 +39,6 @@ jobs: # Login against a Docker registry except on PR # https://github.com/docker/login-action - name: Log into registry ${{ env.REGISTRY }} - if: github.event_name != 'pull_request' uses: docker/login-action@v2 with: registry: ${{ env.REGISTRY }} @@ -59,7 +52,7 @@ jobs: with: context: ./docker file: ./docker/${{ matrix.platform }}.Dockerfile - push: ${{ github.event_name != 'pull_request' }} + push: true build-args: | VERSION=${{ matrix.node }} tags: ${{ env.REGISTRY }}/${{ github.repository }}/node-desktop:${{ matrix.node }}-${{ matrix.platform }} diff --git a/.github/workflows/napi.yml b/.github/workflows/napi.yml index 53e52a8..c1e125d 100644 --- a/.github/workflows/napi.yml +++ b/.github/workflows/napi.yml @@ -145,6 +145,8 @@ jobs: fail-fast: false matrix: settings: + - host: macos-13 + target: x86_64-apple-darwin - host: macos-latest target: aarch64-apple-darwin - host: windows-latest diff --git a/docker/alpine.Dockerfile b/docker/alpine.Dockerfile index 5395612..dda6cfc 100644 --- a/docker/alpine.Dockerfile +++ b/docker/alpine.Dockerfile @@ -1,4 +1,4 @@ -ARG VERSION="18" +ARG VERSION="16" FROM node:${VERSION}-alpine @@ -8,7 +8,7 @@ ENV DISPLAY=":0" \ DISPLAY_HEIGHT="720" RUN apk update && \ - apk add xvfb xfce4 libxcb libxrandr + apk add procps xvfb xfce4 dbus-x11 libxcb libxrandr COPY alpine-init.sh /usr/local/share/alpine-init.sh diff --git a/docker/debian.Dockerfile b/docker/debian.Dockerfile index 22b539c..fb46aa1 100644 --- a/docker/debian.Dockerfile +++ b/docker/debian.Dockerfile @@ -1,4 +1,4 @@ -ARG VERSION="18" +ARG VERSION="16" FROM node:${VERSION}-slim @@ -9,7 +9,7 @@ ENV DEBIAN_FRONTEND=noninteractive \ DISPLAY_HEIGHT="720" RUN apt-get update && \ - apt-get -y install --no-install-recommends xvfb xfce4 dbus-x11 libxcb1 libxrandr2 && \ + apt-get -y install --no-install-recommends procps xvfb xfce4 dbus-x11 libxcb1 libxrandr2 && \ apt-get autoclean -y && \ apt-get autoremove -y && \ rm -rf /var/lib/apt/lists/*