-
-
Notifications
You must be signed in to change notification settings - Fork 41
/
Dockerfile
38 lines (26 loc) · 907 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
FROM node:current-alpine AS build
# working directory for the build
WORKDIR ${HOME}
# Copy package configs into working Directory
COPY ./package.json ./package-lock.json ./tsconfig.json ${HOME}/
# Install required packages
RUN npm ci --omit-dev
# Copy src files into Working Directory
COPY ./src ${HOME}/src
# Compile the project
RUN npx tsc
# Copy built artifacts and dependencies into a minimal release image
FROM node:current-alpine AS release
LABEL Description="Project for automatically organizing and downloading Floatplane videos for plex."
# Create Directory for the Container
WORKDIR /fp
COPY --from=build ${HOME}/node_modules node_modules
COPY --from=build ${HOME}/dist dist
COPY --from=build ${HOME}/package.json package.json
# Environment variables
ENV headless=true
# Define volumes to be mountable
VOLUME /fp/db
VOLUME /fp/videos
# Runs on container start
CMD node ./dist/float.js