|
@@ -485,6 +485,18 @@ RUN if [ ${INSTALL_CALENDAR} = true ]; then \
|
|
|
docker-php-ext-install calendar \
|
|
|
;fi
|
|
|
|
|
|
+###########################################################################
|
|
|
+# libfaketime:
|
|
|
+###########################################################################
|
|
|
+
|
|
|
+USER root
|
|
|
+
|
|
|
+ARG INSTALL_FAKETIME=false
|
|
|
+
|
|
|
+RUN if [ ${INSTALL_FAKETIME} = true ]; then \
|
|
|
+ apt-get install -y libfaketime \
|
|
|
+;fi
|
|
|
+
|
|
|
###########################################################################
|
|
|
# Check PHP version:
|
|
|
###########################################################################
|
|
@@ -509,6 +521,12 @@ RUN apt-get clean && \
|
|
|
|
|
|
RUN usermod -u 1000 www-data
|
|
|
|
|
|
+# Adding the faketime library to the preload file needs to be done last
|
|
|
+# otherwise it will preload it for all commands that follow in this file
|
|
|
+RUN if [ ${INSTALL_FAKETIME} = true ]; then \
|
|
|
+ echo "/usr/lib/x86_64-linux-gnu/faketime/libfaketime.so.1" > /etc/ld.so.preload \
|
|
|
+;fi
|
|
|
+
|
|
|
WORKDIR /var/www
|
|
|
|
|
|
CMD ["php-fpm"]
|