forked from neoxr/neoxr-bot
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
31 lines (24 loc) · 761 Bytes
/
Dockerfile
File metadata and controls
31 lines (24 loc) · 761 Bytes
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
FROM node:14.21.3 AS node_base
ENV NODE_VERSION=14.21.3
RUN apt install -y curl
RUN curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.0/install.sh | bash
ENV NVM_DIR=/root/.nvm
RUN . "$NVM_DIR/nvm.sh" && nvm install ${NODE_VERSION}
RUN . "$NVM_DIR/nvm.sh" && nvm use v${NODE_VERSION}
RUN . "$NVM_DIR/nvm.sh" && nvm alias default v${NODE_VERSION}
ENV PATH="/root/.nvm/versions/node/v${NODE_VERSION}/bin/:${PATH}"
RUN apt-get update && \
apt-get install -y \
nodejs\
ffmpeg \
imagemagick \
build-essential \
python \
webp && \
apt-get upgrade -y && \
rm -rf /var/lib/apt/lists/*
COPY package.json .
RUN yarn global add node-pre-gyp@v0.7.x && yarn global add node-pre && yarn install
COPY . .
EXPOSE 5000
CMD ["node", "index.js"]