Upgrade to PHP 8

main
Igor Scheller 4 years ago committed by msquare
parent c2b2487721
commit 6aca6f08e2

@ -28,7 +28,7 @@ COPY --from=composer /app/composer.lock /app/
RUN find /app/storage/ -type f -not -name VERSION -exec rm {} \; RUN find /app/storage/ -type f -not -name VERSION -exec rm {} \;
# Build the PHP container # Build the PHP container
FROM php:7-fpm-alpine FROM php:8-fpm-alpine
WORKDIR /var/www WORKDIR /var/www
RUN apk add --no-cache icu-dev && \ RUN apk add --no-cache icu-dev && \
docker-php-ext-install intl pdo_mysql docker-php-ext-install intl pdo_mysql

@ -1,11 +1,11 @@
# Engelsystem PHP FPM development image including Xdebug # Engelsystem PHP FPM development image including Xdebug
FROM php:7-fpm-alpine AS es_php_fpm FROM php:8-fpm-alpine AS es_php_fpm
WORKDIR /var/www WORKDIR /var/www
RUN apk add --no-cache icu-dev $PHPIZE_DEPS && \ RUN apk add --no-cache icu-dev $PHPIZE_DEPS && \
pecl install pcov xdebug && \ pecl install pcov xdebug && \
docker-php-ext-install intl pdo_mysql && \ docker-php-ext-install intl pdo_mysql && \
docker-php-ext-enable pcov xdebug docker-php-ext-enable pcov xdebug
RUN echo -e "xdebug.remote_enable=1\nxdebug.remote_connect_back=1\n" >> /usr/local/etc/php/conf.d/xdebug.ini RUN echo -e "xdebug.mode=debug\nxdebug.discover_client_host=1\n" >> /usr/local/etc/php/conf.d/xdebug.ini
ENV TRUSTED_PROXIES 10.0.0.0/8,::ffff:10.0.0.0/8,\ ENV TRUSTED_PROXIES 10.0.0.0/8,::ffff:10.0.0.0/8,\
127.0.0.0/8,::ffff:127.0.0.0/8,\ 127.0.0.0/8,::ffff:127.0.0.0/8,\

@ -11,6 +11,9 @@ http {
scgi_temp_path /tmp/scgi_temp; scgi_temp_path /tmp/scgi_temp;
uwsgi_temp_path /tmp/uwsgi_temp; uwsgi_temp_path /tmp/uwsgi_temp;
fastcgi_buffers 16 16k;
fastcgi_buffer_size 32k;
map $http_x_forwarded_proto $forwarded_proto { map $http_x_forwarded_proto $forwarded_proto {
default $http_x_forwarded_proto; default $http_x_forwarded_proto;
https https; https https;

@ -115,12 +115,15 @@ function load_rooms()
*/ */
function load_days() function load_days()
{ {
$days = DB::select(' $days = (new Collection(DB::select(
'
SELECT DISTINCT DATE(FROM_UNIXTIME(`start`)) AS `id`, DATE(FROM_UNIXTIME(`start`)) AS `name` SELECT DISTINCT DATE(FROM_UNIXTIME(`start`)) AS `id`, DATE(FROM_UNIXTIME(`start`)) AS `name`
FROM `Shifts` FROM `Shifts`
ORDER BY `id`, `name` ORDER BY `id`, `name`
'); '
$days = array_map('array_shift', $days); )))
->pluck('id')
->toArray();
if (empty($days)) { if (empty($days)) {
error(__('The administration has not configured any shifts yet.')); error(__('The administration has not configured any shifts yet.'));

Loading…
Cancel
Save