-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
59 lines (50 loc) · 1.3 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
FROM alpine:3.20
RUN apk add --no-cache \
php83 \
php83-fpm \
php83-opcache \
php83-cli \
php83-mbstring \
php83-xml \
php83-curl \
php83-pecl-redis \
php83-pecl-memcached \
php83-pcntl \
php83-posix \
php83-pdo \
php83-pdo_pgsql \
php83-zip \
php83-tokenizer \
php83-json \
php83-phar \
php83-fileinfo \
php83-dom \
php83-session \
php83-simplexml \
php83-xmlwriter \
php83-soap \
php83-openssl \
php83-bcmath \
php83-gd \
php83-intl \
vim \
nginx \
npm \
curl \
wireguard-tools \
unzip
RUN getent passwd www-data || adduser -S -G www-data -s /usr/sbin/nologin www-data
RUN ln -sf /usr/bin/php83 /usr/bin/php
RUN curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer
WORKDIR /var/www/
COPY . /var/www/
RUN composer install --no-dev --optimize-autoloader
RUN chown -R www-data:www-data /var/www \
&& chmod -R 775 /var/www
COPY docker/www.conf /etc/php83/php-fpm.d/www.conf
COPY docker/nginx.conf /etc/nginx/nginx.conf
COPY docker/default.conf /etc/nginx/http.d/default.conf
COPY docker/laravel-scripts.sh /usr/local/bin/laravel-scripts.sh
RUN chmod 755 /etc/nginx/http.d/default.conf
RUN chmod 755 /usr/local/bin/laravel-scripts.sh
EXPOSE 80