2024-08-19 12:12:56 +02:00
|
|
|
ARG BUILD_FROM
|
2024-08-28 12:41:55 +02:00
|
|
|
FROM $BUILD_FROM
|
|
|
|
|
|
|
|
ENV LANG C.UTF-8
|
|
|
|
|
|
|
|
# Install DoliDeb
|
|
|
|
RUN apk add --no-cache apache2 php php-mysqli php-curl php-json php-session php-xml php-mbstring php-gd php-intl php-zip curl bash \
|
|
|
|
&& curl -L -o dolibarr.tar.gz https://sourceforge.net/projects/dolibarr/files/latest/download && \
|
|
|
|
if [ -f "dolibarr.tar.gz" ]; then \
|
|
|
|
tar xzf dolibarr.tar.gz -C /var/www/localhost/htdocs/; \
|
|
|
|
rm dolibarr.tar.gz; \
|
|
|
|
else \
|
|
|
|
echo "Download failed or file does not exist."; \
|
|
|
|
exit 1; \
|
|
|
|
fi
|
|
|
|
|
|
|
|
# 4. Copy s6-overlay configuration files (rootfs structure)
|
2024-08-19 16:37:11 +02:00
|
|
|
COPY rootfs/ /
|
|
|
|
|
2024-08-28 12:41:55 +02:00
|
|
|
# 5. Set permissions and prepare s6-overlay
|
|
|
|
RUN chmod +x /etc/services.d/dolideb/run
|
2024-08-19 12:12:56 +02:00
|
|
|
|
2024-08-28 12:41:55 +02:00
|
|
|
# 6. Expose HTTP port
|
|
|
|
EXPOSE 80
|
2024-08-19 12:12:56 +02:00
|
|
|
|
2024-08-28 12:41:55 +02:00
|
|
|
# 7. Start the s6-overlay init system
|
|
|
|
ENTRYPOINT ["/init"]
|