feat: support docker image building
This commit is contained in:
parent
79f08733df
commit
b849014aab
|
@ -0,0 +1,9 @@
|
|||
{
|
||||
admin off
|
||||
}
|
||||
|
||||
:80 {
|
||||
root * /www
|
||||
file_server
|
||||
try_files {path} /
|
||||
}
|
|
@ -0,0 +1,14 @@
|
|||
FROM node:18 as builder
|
||||
COPY . /app
|
||||
|
||||
RUN npm config set registry https://registry.npmmirror.com \
|
||||
&& npm config set disturl https://npmmirror.com/dist --location=global \
|
||||
&& npm i --location=global pnpm
|
||||
|
||||
WORKDIR /app
|
||||
RUN pnpm install \
|
||||
&& pnpm build
|
||||
|
||||
FROM caddy:alpine
|
||||
COPY Caddyfile /etc/caddy
|
||||
COPY dist /www
|
Loading…
Reference in New Issue