File size: 1,089 Bytes
e36abe9
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
28803d8
 
1a1da9e
e36abe9
 
 
 
 
 
 
 
 
 
 
 
 
 
1a1da9e
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
FROM nikolaik/python-nodejs:latest

ARG DEBIAN_FRONTEND noninteractive
RUN apt update && apt upgrade -y
RUN apt install -y build-essential \
 curl fastfetch ffmpeg imagemagick \
 libcairo2-dev libpango1.0-dev \
 libjpeg-dev libgif-dev librsvg2-dev \
 nginx

RUN curl -LO https://github.com/dengsgo/echofs/releases/latest/download/echofs-linux-amd64.tar.gz
RUN tar -xzvf echofs-linux-amd64.tar.gz
RUN mv -vf echofs /usr/local/bin/

RUN echo 'events {} http { \
 server { \
  listen 7860; \
  location /stats { proxy_pass http://127.0.0.1:3000/stats; } \
  location /eval { proxy_pass http://127.0.0.1:3000/eval; } \
  location / { proxy_pass http://127.0.0.1:8080; } \
 } \
}' > /etc/nginx/nginx.conf

WORKDIR /tmp/.app
RUN npm i -g tunn3l
RUN npm i attp-generator express \
 ky morgan playwright playwright-extra \
 pretty-ms qc-generator-whatsapp
RUN npx playwright install chromium
RUN npx playwright install-deps

RUN chmod -R 777 /tmp && mkdir -p /tmp/qc
COPY . .
ENV PORT 3000
CMD ["sh", "-c", "node . & echofs -r /tmp -H & tunn3l http 7860 --subdomain ripp & nginx -g 'daemon off;'"]