-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
30 lines (24 loc) · 963 Bytes
/
Dockerfile
File metadata and controls
30 lines (24 loc) · 963 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
FROM ubuntu:latest
# copy directories
COPY ./config ./hisu_bot/config
COPY ./src ./hisu_bot/src
COPY ./dependencies.txt ./hisu_bot
# install nodejs, npm, and pm2
RUN apt-get update
RUN apt-get -y install curl
RUN apt -y install nodejs npm
RUN npm install pm2 -g
# install python3 and pip3
ENV TZ=US/Pacific
RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
RUN apt-get update && apt install build-essential software-properties-common -y && \
add-apt-repository ppa:deadsnakes/ppa
RUN apt-get update && apt install python3.11 -y
RUN apt-get -y install python3-pip
# install 3rd party python dependencies
RUN pip3 install -r ./hisu_bot/dependencies.txt
ENV PYTHONPATH=$PYTHONPATH:/hisu_bot/src/modules
# run bot
CMD ["python3", "./hisu_bot/src/hisu.py"]
# CMD ["pm2", "start", "./hisu_bot/src/hisu.py", "--name", "hisu_bot", "--interpreter", "python3"]
# pm2 start ./hisu_bot/src/hisu.py --name hisu_bot --interpreter python3