mirror of
https://github.com/librespeed/speedtest.git
synced 2026-07-10 10:34:01 +00:00
Merge 265c42d4bf into a293ac4cb9
This commit is contained in:
commit
4b40fb6e63
3 changed files with 18 additions and 0 deletions
|
|
@ -10,6 +10,8 @@ RUN install-php-extensions iconv gd pdo pdo_mysql pdo_pgsql pgsql \
|
|||
&& apt-get clean \
|
||||
&& rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
|
||||
|
||||
COPY docker/librespeed-php.ini ${PHP_INI_DIR}/conf.d/99-librespeed.ini
|
||||
|
||||
# Prepare files and folders
|
||||
RUN mkdir -p /speedtest/
|
||||
|
||||
|
|
|
|||
|
|
@ -20,6 +20,17 @@ RUN apk add --quiet --no-cache \
|
|||
RUN ln -sf /dev/stdout /var/log/apache2/access.log && \
|
||||
ln -sf /dev/stderr /var/log/apache2/error.log
|
||||
|
||||
# Install the ini into the scan dir PHP itself reports.
|
||||
COPY docker/librespeed-php.ini /tmp/librespeed-php.ini
|
||||
RUN set -eu; \
|
||||
scan_dir="$(php -r 'echo rtrim(PHP_CONFIG_FILE_SCAN_DIR);')"; \
|
||||
if [ -z "$scan_dir" ]; then \
|
||||
echo "ERROR: PHP_CONFIG_FILE_SCAN_DIR is empty" >&2; \
|
||||
exit 1; \
|
||||
fi; \
|
||||
install -m 0644 /tmp/librespeed-php.ini "$scan_dir/99-librespeed.ini"; \
|
||||
rm /tmp/librespeed-php.ini
|
||||
|
||||
# Prepare files and folders
|
||||
RUN mkdir -p /speedtest/
|
||||
|
||||
|
|
|
|||
5
docker/librespeed-php.ini
Normal file
5
docker/librespeed-php.ini
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
; speedtest_worker.js defaults xhr_ul_blob_megabytes to 20.
|
||||
; PHP's stock post_max_size = 8M rejects those upload chunks before
|
||||
; empty.php can send its headers. 32M leaves modest headroom.
|
||||
|
||||
post_max_size = 32M
|
||||
Loading…
Add table
Add a link
Reference in a new issue