mirror of
https://github.com/librespeed/speedtest.git
synced 2026-06-29 13:22:23 +00:00
ci: add alpine dockerfile
Signed-off-by: rare-magma <rare-magma@posteo.eu>
This commit is contained in:
parent
f8f290a2e8
commit
d1aa403f38
1 changed files with 53 additions and 0 deletions
53
Dockerfile.alpine
Executable file
53
Dockerfile.alpine
Executable file
|
|
@ -0,0 +1,53 @@
|
|||
FROM php:8-alpine
|
||||
|
||||
# Install extensions
|
||||
RUN apk add --quiet --no-cache \
|
||||
bash \
|
||||
apache2 \
|
||||
apache2-ssl \
|
||||
php82-apache2 \
|
||||
php82-ctype \
|
||||
php82-openssl \
|
||||
freetype-dev \
|
||||
libjpeg-turbo-dev \
|
||||
libpng-dev \
|
||||
libpq-dev
|
||||
RUN docker-php-ext-configure gd --with-freetype=/usr/include/ --with-jpeg=/usr/include/ \
|
||||
&& docker-php-ext-configure pgsql -with-pgsql=/usr/local/pgsql \
|
||||
&& docker-php-ext-install -j$(nproc) gd pdo pdo_mysql pdo_pgsql pgsql
|
||||
RUN ln -sf /dev/stdout /var/log/apache2/access.log && \
|
||||
ln -sf /dev/stderr /var/log/apache2/error.log
|
||||
|
||||
# Prepare files and folders
|
||||
RUN mkdir -p /speedtest/
|
||||
|
||||
# Copy sources
|
||||
COPY backend/ /speedtest/backend
|
||||
|
||||
COPY results/*.php /speedtest/results/
|
||||
COPY results/*.ttf /speedtest/results/
|
||||
|
||||
COPY *.js /speedtest/
|
||||
COPY favicon.ico /speedtest/
|
||||
|
||||
COPY docker/servers.json /servers.json
|
||||
|
||||
COPY docker/*.php /speedtest/
|
||||
COPY docker/entrypoint.sh /
|
||||
|
||||
# Prepare default environment variables
|
||||
ENV TITLE=LibreSpeed
|
||||
ENV MODE=standalone
|
||||
ENV PASSWORD=password
|
||||
ENV TELEMETRY=false
|
||||
ENV ENABLE_ID_OBFUSCATION=false
|
||||
ENV REDACT_IP_ADDRESSES=false
|
||||
ENV WEBPORT=80
|
||||
ENV APACHE_DOCUMENT_ROOT=/var/www/html
|
||||
|
||||
# https://httpd.apache.org/docs/2.4/stopping.html#gracefulstop
|
||||
STOPSIGNAL SIGWINCH
|
||||
|
||||
# Final touches
|
||||
EXPOSE 80
|
||||
CMD ["bash", "/entrypoint.sh"]
|
||||
Loading…
Add table
Add a link
Reference in a new issue