Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/develop' into develop
Browse files Browse the repository at this point in the history
  • Loading branch information
Phocacius committed Jun 26, 2024
2 parents e6f5441 + 1bbd7f5 commit 3088277
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 8 deletions.
2 changes: 0 additions & 2 deletions .github/workflows/docker-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@ name: Build and push release Docker image

on:
push:
branches:
- "master"
tags:
- "v*"

Expand Down
25 changes: 19 additions & 6 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
FROM php:8.3-apache
FROM php:8.3-apache as base-container

ENV APACHE_DOCUMENT_ROOT /var/mapbender/application/public

RUN apt-get update && apt-get install -y \
libpq-dev \
git \
vim \
unzip \
openssl \
bzip2 \
Expand All @@ -20,7 +18,8 @@ RUN apt-get update && apt-get install -y \
libsqlite3-dev \
libldap2-dev \
libonig-dev \
postgresql-client
postgresql-client \
&& rm -rf /var/lib/apt/lists/*

RUN docker-php-ext-install pdo_pgsql
RUN docker-php-ext-install curl gd intl mbstring zip bz2 xml pdo_sqlite ldap
Expand All @@ -34,13 +33,27 @@ RUN a2enmod rewrite remoteip

RUN chown www-data:www-data -R /var/www

USER www-data

WORKDIR /var/mapbender/

EXPOSE 8080

COPY --chown=www-data:www-data . /var/mapbender/

FROM base-container as build-container

RUN apt-get update && apt-get install -y \
git \
&& rm -rf /var/lib/apt/lists/*

USER www-data
# required to create a complete mapbender application container image including all dependencies
RUN ./bootstrap


FROM base-container

USER www-data

COPY --from=build-container --chown=www-data:www-data /var/mapbender /var/mapbender

CMD ["apache2-foreground"]

0 comments on commit 3088277

Please sign in to comment.