Try fpm
This commit is contained in:
parent
a9a5f113ee
commit
7c76d97d04
|
@ -1,4 +1,4 @@
|
||||||
FROM arm64v8/php:7.4.1-apache-buster
|
FROM arm64v8/php:7.4.1-fpm-buster
|
||||||
|
|
||||||
RUN set -ex; \
|
RUN set -ex; \
|
||||||
\
|
\
|
||||||
|
@ -56,15 +56,6 @@ RUN echo 'memory_limit=512M' > /usr/local/etc/php/conf.d/memory-limit.ini; \
|
||||||
chown -R www-data:root /var/www; \
|
chown -R www-data:root /var/www; \
|
||||||
chmod -R g=u /var/www
|
chmod -R g=u /var/www
|
||||||
|
|
||||||
RUN a2enmod rewrite remoteip ;\
|
|
||||||
{\
|
|
||||||
echo RemoteIPHeader X-Real-IP ;\
|
|
||||||
echo RemoteIPTrustedProxy 10.0.0.0/8 ;\
|
|
||||||
echo RemoteIPTrustedProxy 172.16.0.0/12 ;\
|
|
||||||
echo RemoteIPTrustedProxy 192.168.0.0/16 ;\
|
|
||||||
} > /etc/apache2/conf-available/remoteip.conf;\
|
|
||||||
a2enconf remoteip
|
|
||||||
|
|
||||||
RUN mkdir /scratch
|
RUN mkdir /scratch
|
||||||
|
|
||||||
WORKDIR /scratch
|
WORKDIR /scratch
|
||||||
|
@ -91,7 +82,8 @@ RUN chown -R www-data:root /var/www; \
|
||||||
|
|
||||||
USER www-data
|
USER www-data
|
||||||
RUN rm -rf /var/www/html
|
RUN rm -rf /var/www/html
|
||||||
RUN git clone -b $TAG https://github.com/pixelfed/pixelfed /var/www/html
|
RUN git clone -b $TAG https://github.com/pixelfed/pixelfed /var/www/pixelfed; \
|
||||||
|
ln -s /var/www/pixelfed/public /var/www/html
|
||||||
USER root
|
USER root
|
||||||
|
|
||||||
RUN apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false $fetchDeps; \
|
RUN apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false $fetchDeps; \
|
||||||
|
@ -103,7 +95,7 @@ RUN apt-get update; \
|
||||||
|
|
||||||
USER www-data
|
USER www-data
|
||||||
|
|
||||||
WORKDIR /var/www/html
|
WORKDIR /var/www/pixelfed
|
||||||
|
|
||||||
RUN composer install \
|
RUN composer install \
|
||||||
--no-ansi \
|
--no-ansi \
|
||||||
|
@ -123,7 +115,9 @@ COPY pixelfed-startup /usr/local/bin/pixelfed-startup
|
||||||
COPY pixelfed-migrate /usr/local/bin/pixelfed-migrate
|
COPY pixelfed-migrate /usr/local/bin/pixelfed-migrate
|
||||||
COPY pixelfed-garbage /usr/local/bin/pixelfed-garbage
|
COPY pixelfed-garbage /usr/local/bin/pixelfed-garbage
|
||||||
|
|
||||||
VOLUME /var/www/html/storage
|
RUN echo "chdir = /var/www/html" >> /usr/local/etc/php-fpm.d/www.conf
|
||||||
|
|
||||||
ENTRYPOINT ["/usr/bin/tini", "--"]
|
VOLUME /var/www/pixelfed/storage
|
||||||
CMD ["/usr/local/bin/pixelfed-startup", "/usr/local/bin/apache2-foreground"]
|
|
||||||
|
ENTRYPOINT ["tini", "--"]
|
||||||
|
CMD ["pixelfed-startup", "php-fpm"]
|
||||||
|
|
Loading…
Reference in a new issue