chore: 修改VERSION传递方式,从env改为build-arg

pull/70/head
moonrailgun 2 years ago
parent 816167517f
commit b317731748

@ -44,5 +44,4 @@ jobs:
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
env:
VERSION: docker-${{ steps.meta.outputs.tags }}
build-args: VERSION=docker-${{ steps.meta.outputs.tags }}

@ -1,5 +1,8 @@
FROM node:lts-alpine
# use with --build-arg VERSION=xxxx
ARG VERSION
# Working directory
WORKDIR /app/tailchat
@ -31,6 +34,7 @@ RUN pnpm install
# Build and cleanup (client and server)
ENV NODE_ENV=production
ENV VERSION=$VERSION
RUN pnpm run build
# web static service port

Loading…
Cancel
Save