-
Notifications
You must be signed in to change notification settings - Fork 8
/
Dockerfile
41 lines (32 loc) · 1.02 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
FROM php:7.0-apache
# Set default system timezone
RUN ln -sf /usr/share/zoneinfo/Europe/Paris /etc/localtime
# Install last update and php extension
RUN apt-get update && apt-get install -y --no-install-recommends \
vim \
bzip2 \
zip \
unzip \
libbz2-dev \
libmcrypt-dev \
libicu-dev \
&& docker-php-ext-configure mysqli \
&& docker-php-ext-install mysqli pdo_mysql bz2 mcrypt intl \
&& rm -rf /var/lib/apt/lists/*
# Install composer
RUN curl -sS https://getcomposer.org/installer | php \
&& mv composer.phar /usr/bin/composer
# Enable Apache Rewrite module
RUN a2enmod rewrite
# Default Vhost for developement
COPY resources/vhost.conf /etc/apache2/sites-available/000-default.conf
# Implement application
WORKDIR /var/app
COPY . /var/app/
# Update project
#RUN /usr/bin/composer install --no-dev \
# && ./scripts/post-create-project \
# && chown www-data:www-data -R .
COPY resources/entrypoint.sh /
RUN chmod 755 /entrypoint.sh
ENTRYPOINT ["/entrypoint.sh", "apache2-foreground"]