-
Notifications
You must be signed in to change notification settings - Fork 10
/
Dockerfile
51 lines (30 loc) · 926 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
FROM node:20-alpine AS base
ARG TURBO_TEAM
ENV TURBO_TEAM=$TURBO_TEAM
RUN --mount=type=secret,id=TURBO_TOKEN,env=TURBO_TOKEN
ENV PNPM_HOME="/pnpm"
ENV PATH="$PNPM_HOME:$PATH"
RUN corepack enable && corepack install -g pnpm@latest-9
WORKDIR /app
COPY pnpm-lock.yaml .
FROM base AS builder
RUN pnpm install -g turbo
COPY . .
RUN turbo prune deemix-webui --docker
FROM base AS installer
COPY --from=builder /app/out/json/ .
RUN apk add --no-cache python3 make g++
RUN pnpm install --frozen-lockfile
COPY --from=builder /app/out/full/ .
RUN pnpm turbo build --filter=deemix-webui...
FROM ghcr.io/linuxserver/baseimage-alpine:3.20 AS runner
RUN apk add --no-cache nodejs=~20
COPY --from=installer /app /app
COPY docker/ /
ENV DEEMIX_DATA_DIR=/config/
ENV DEEMIX_MUSIC_DIR=/downloads/
ENV DEEMIX_SERVER_PORT=6595
ENV DEEMIX_HOST=0.0.0.0
ENV NODE_ENV=production
EXPOSE $DEEMIX_SERVER_PORT
ENTRYPOINT [ "/init" ]