-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
72 lines (58 loc) · 1.58 KB
/
Dockerfile
File metadata and controls
72 lines (58 loc) · 1.58 KB
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
65
66
67
68
69
70
71
72
FROM serversideup/php:8.4-fpm-nginx-alpine
COPY --chmod=755 common/etc/entrypoint.d /etc/entrypoint.d
COPY --chmod=755 common/etc/s6-overlay /etc/s6-overlay
COPY --chmod=755 --chown=www-data:www-data common/etc/nginx /etc/nginx
COPY --chmod=755 common/usr/local/bin /usr/local/bin
# PHP limits
ENV PHP_MEMORY_LIMIT=256M
ENV PHP_POST_MAX_SIZE=100M
ENV PHP_UPLOAD_MAX_FILE_SIZE=${PHP_POST_MAX_SIZE}
# OPcache settings
ENV PHP_OPCACHE_ENABLE=1
ENV PHP_OPCACHE_INTERNED_STRINGS_BUFFER=8
ENV PHP_OPCACHE_MEMORY_CONSUMPTION=128
ENV PHP_OPCACHE_REVALIDATE_FREQ=2
# PHP-FPM settings
ENV PHP_FPM_PM_CONTROL=ondemand
ENV PHP_FPM_PM_MAX_CHILDREN=20
ENV PHP_FPM_PM_START_SERVERS=2
ENV PHP_FPM_PM_MIN_SPARE_SERVERS=1
ENV PHP_FPM_PM_MAX_SPARE_SERVERS=3
# Laravel settings
ENV AUTORUN_ENABLED=true
ENV AUTORUN_LARAVEL_MIGRATION=true
ENV AUTORUN_LARAVEL_STORAGE_LINK=true
ENV AUTORUN_LARAVEL_OPTIMIZE=true
ENV AUTORUN_LARAVEL_FILAMENT=true
ENV HEALTHCHECK_PATH=/up
# Composer settings
ENV COMPOSER_ALLOW_SUPERUSER=0
ENV COMPOSER_CACHE_DIR=/dev/null
ENV COMPOSER_FUND=0
ENV COMPOSER_HOME=/tmp
ENV COMPOSER_NO_DEV=1
ENV COMPOSER_NO_INTERACTION=1
# App defaults
ENV LOG_CHANNEL=stderr
# Schedule settings
ENV SCHEDULE_ENABLED=true
# Queue settings
ENV QUEUE_ENABLED=false
ENV QUEUE_MAX_JOBS=50
ENV QUEUE_SLEEP=30
ENV QUEUE_REST=1
ENV QUEUE_TIMEOUT=600
ENV QUEUE_TRIES=3
# Switch to root so we can do root things
USER root
# Install additional PHP extensions
RUN set -ex; \
install-php-extensions \
event \
excimer \
exif \
gd \
intl;
# Drop back to our unprivileged user
USER www-data
EXPOSE 8080 8443