-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile.ns-flask
54 lines (40 loc) · 1.47 KB
/
Dockerfile.ns-flask
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
52
53
54
# FROM ghcr.io/lnls-sirius/docker-machine-applications/debian:bullseye-20211011
FROM ns-base
SHELL ["bash", "-c"]
RUN pip-sirius install \
alembic==1.7.7 \
email-validator==1.3.1 \
Flask==2.0.3 \
Flask_Login==0.5.0 \
Flask_Migrate==4.0.1 \
Flask_SQLAlchemy==2.5.1 \
Flask_WTF==1.0.1 \
gunicorn==22.0.0 \
gevent==24.2.1 \
num2words==0.5.13 \
phonenumbers==8.13.30 \
psutil==5.9.7 \
pyserial==3.5 \
pywhatkit==5.4 \
Requests==2.32.3 \
SQLAlchemy==1.4.51 \
urllib3==1.26.18 \
Werkzeug==2.0.3 \
WTForms==3.0.0
RUN apt-get install -y \
udev
# firefox
# ENV DISPLAY=:0
COPY ./50-modem-usb.rules /etc/udev/rules.d/50-usbmodem.rules
RUN cd repos && git clone https://github.com/lnls-sirius/notification_service.git
WORKDIR /opt/repos/notification_service
# Expose the application port
EXPOSE 5000
# Command to run Gunicorn
CMD ["gunicorn", "--bind", "0.0.0.0:5000", "notificationservice:app"]
# AT\rAT+CMGS="+55199997397443"\rTeste\z
# RUN udevadm control --reload
# docker run -it --network host --device=/dev/ttyUSB0 ns-flask bash
# docker run --mount type=bind,source=/opt/notification_service/db/,target=/opt/repos/notification_service/app/db/ -it --network host --device=/dev/ttyUSB0 ns-flask bash
# docker run -it -p 10.20.31.144:5000:5000 --mount type=bind,source=/opt/notification_service/db/,target=/opt/repos/notification_service/app/db/ ns-flask
# docker build -f ./Dockerfile.ns-flask . -t ns-flask