fix: перенести сборку фронта на хост CI, убрать ui-build стадию из Docker
Some checks failed
Build and Deploy Gateway / build-and-deploy (push) Failing after 0s
Some checks failed
Build and Deploy Gateway / build-and-deploy (push) Failing after 0s
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
node_modules
|
||||
dist
|
||||
.vpn-proxy
|
||||
_archive
|
||||
.git
|
||||
|
||||
@@ -23,6 +23,13 @@ jobs:
|
||||
cd repo
|
||||
git checkout ${{ gitea.sha }}
|
||||
|
||||
- name: Build frontend
|
||||
run: |
|
||||
set -euo pipefail
|
||||
cd repo
|
||||
npm ci --no-audit --no-fund
|
||||
npm run build
|
||||
|
||||
- name: Build and push gateway image
|
||||
run: |
|
||||
set -euo pipefail
|
||||
|
||||
11
Dockerfile
11
Dockerfile
@@ -1,15 +1,6 @@
|
||||
FROM node:22-bookworm-slim AS ui-build
|
||||
WORKDIR /app
|
||||
COPY package.json package-lock.json ./
|
||||
RUN --mount=type=cache,target=/root/.npm \
|
||||
npm ci --no-audit --no-fund --network-timeout=300000
|
||||
COPY index.html vite.config.js ./
|
||||
COPY src/web ./src/web
|
||||
RUN npm run build
|
||||
|
||||
FROM debian:bookworm-slim
|
||||
ARG SINGBOX_VERSION=1.12.13
|
||||
COPY --from=ui-build /app/dist /app/dist
|
||||
COPY dist /app/dist
|
||||
|
||||
RUN apt-get update \
|
||||
&& apt-get install -y --no-install-recommends ca-certificates curl iptables iproute2 nodejs dumb-init \
|
||||
|
||||
Reference in New Issue
Block a user