Skip to content

Commit d0998d7

Browse files
committed
fix docker var replace
1 parent 056f1d5 commit d0998d7

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
FROM node:lts-alpine as build-stage
33
WORKDIR /app
44
COPY package*.json ./
5-
ENV VITE_APP_PUBLIC_PATH <PUBLIC_PATH_REPLACE>
5+
ENV VITE_APP_PUBLIC_PATH __PUBLIC_PATH_REPLACE__
66
RUN npm install
77
COPY . .
88
RUN npm run build

entrypoint.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,6 @@
22
set -e
33
: "${UI_PUBLIC_PATH:=}"
44

5-
sed -i "s@/<PUBLIC_PATH_REPLACE>@$UI_PUBLIC_PATH@g" /usr/share/nginx/html/index.html
6-
sed -i "s@/<PUBLIC_PATH_REPLACE>@$UI_PUBLIC_PATH@g" /usr/share/nginx/html/assets/index*.js
7-
sed -i "s@/<PUBLIC_PATH_REPLACE>@$UI_PUBLIC_PATH@g" /usr/share/nginx/html/assets/index*.css
5+
sed -i "s@/__PUBLIC_PATH_REPLACE__@$UI_PUBLIC_PATH@g" /usr/share/nginx/html/index.html
6+
sed -i "s@/__PUBLIC_PATH_REPLACE__@$UI_PUBLIC_PATH@g" /usr/share/nginx/html/assets/index*.js
7+
sed -i "s@/__PUBLIC_PATH_REPLACE__@$UI_PUBLIC_PATH@g" /usr/share/nginx/html/assets/index*.css

0 commit comments

Comments
 (0)