This repository has been archived by the owner on Jul 31, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 38
/
Copy pathDockerfile
64 lines (55 loc) · 1.59 KB
/
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
FROM ubuntu:20.04
ARG DEBIAN_FRONTEND=noninteractive
MAINTAINER [email protected]
# Install requirements
RUN apt-get update -y \
&& apt-get install -y \
curl \
wget \
ca-certificates \
cron\
sudo\
git \
unzip \
supervisor \
ssh \
git \
apt-transport-https \
daemontools \
php7.4-fpm \
php7.4-json \
php7.4-cli \
php7.4-intl \
php7.4-curl \
php7.4-xml \
nginx \
apache2-utils \
&& apt-get -y --purge autoremove \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
# Configure PHP and Nginx
RUN mkdir /run/php \
&& echo "daemon off;" >> /etc/nginx/nginx.conf \
&& echo "ssl_session_cache shared:SSL:5m; ssl_session_timeout 1h;" >> /etc/nginx/conf.d/ssl_session.conf
# Version Toran Proxy
ENV TORAN_PROXY_VERSION 1.5.4
# Download Toran Proxy
RUN mkdir -p /var/www
RUN curl -sL https://toranproxy.com/releases/toran-proxy-v${TORAN_PROXY_VERSION}.tgz | tar xzC /tmp \
&& mv /tmp/toran/* /var/www
# Load Scripts bash for installing Toran Proxy
COPY scripts /scripts/toran-proxy/
RUN chmod -R u+x /scripts/toran-proxy
# Load binaries
COPY bin /bin/toran-proxy/
RUN chmod -R u+x /bin/toran-proxy
ENV PATH $PATH:/bin/toran-proxy
# Load assets
COPY assets/supervisor/conf.d /etc/supervisor/conf.d
COPY assets/supervisor/supervisord.conf /etc/supervisor/supervisord.conf
COPY assets/vhosts /etc/nginx/sites-available
COPY assets/config /assets/config
VOLUME /data/toran-proxy
EXPOSE 80
EXPOSE 443
CMD /scripts/toran-proxy/launch.sh