-
Notifications
You must be signed in to change notification settings - Fork 5
/
Dockerfile
41 lines (26 loc) · 1020 Bytes
/
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
FROM ubuntu:20.04 as base
WORKDIR /
EXPOSE 443
FROM php:7.4-apache as build
WORKDIR /
ENV CONFPATH = ""
RUN apt-get update
RUN apt install default-mysql-client -y
RUN apt install nano
RUN apt-get update \
&& apt-get install -y git
RUN docker-php-ext-install pdo pdo_mysql mysqli
RUN openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout /etc/ssl/private/default.key -out /etc/ssl/certs/default.pem -subj "/C=IL/ST=TelAviv/L=Raanana/O=Security/OU=Development/[email protected]"
RUN docker-php-ext-install mysqli
# RUN mv "$PHP_INI_DIR/php.ini-development" "$PHP_INI_DIR/php.ini"
RUN printf "\n" | pecl install apcu -y
# RUN apt install -y ssl-cert
RUN a2enmod ssl
# RUN a2ensite default-ssl.conf
COPY / /var/www/
COPY ./conf/default.conf /etc/apache2/sites-available
COPY ./conf/default-ssl.conf /etc/apache2/sites-available
RUN a2ensite default-ssl
RUN chown -R www-data:www-data /var/www
RUN chmod 666 /var/www/machine/core/Configurations.php
CMD ["/usr/sbin/apachectl", "-D", "FOREGROUND"]