tac

fleetbase-api (prod)

Published 2026-01-21 06:26:33 +02:00 by steve.vandeheuvel

Installation

docker pull git.brainwashed.co.za/tac/fleetbase-api:prod
sha256:663abc866629c8b98645bee800a2c6683590a56bfa959d86ee1feee62bd121bb

About this package

The modern PHP app server

Image layers

# debian.sh --arch 'arm64' out/ 'bookworm' '@1768176000'
RUN /bin/sh -c set -eux; { echo 'Package: php*'; echo 'Pin: release *'; echo 'Pin-Priority: -1'; } > /etc/apt/preferences.d/no-debian-php # buildkit
ENV PHPIZE_DEPS=autoconf dpkg-dev file g++ gcc libc-dev make pkg-config re2c
RUN /bin/sh -c set -eux; apt-get update; apt-get install -y --no-install-recommends $PHPIZE_DEPS ca-certificates curl xz-utils ; rm -rf /var/lib/apt/lists/* # buildkit
ENV PHP_INI_DIR=/usr/local/etc/php
RUN /bin/sh -c set -eux; mkdir -p "$PHP_INI_DIR/conf.d"; [ ! -d /var/www/html ]; mkdir -p /var/www/html; chown www-data:www-data /var/www/html; chmod 1777 /var/www/html # buildkit
ENV PHP_CFLAGS=-fstack-protector-strong -fpic -fpie -O2 -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64
ENV PHP_CPPFLAGS=-fstack-protector-strong -fpic -fpie -O2 -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64
ENV PHP_LDFLAGS=-Wl,-O1 -pie
ENV GPG_KEYS=AFD8691FDAEDF03BDF6E460563F15A9B715376CA 9D7F99A0CB8F05C8A6958D6256A97AF7600A39A6 0616E93D95AF471243E26761770426E17EBBB3DD
ENV PHP_VERSION=8.4.17
ENV PHP_URL=https://www.php.net/distributions/php-8.4.17.tar.xz PHP_ASC_URL=https://www.php.net/distributions/php-8.4.17.tar.xz.asc
ENV PHP_SHA256=28b234e347286158cae921d61283eb1169d89bc9d2e5f5976567260ff38b0bfa
RUN /bin/sh -c set -eux; savedAptMark="$(apt-mark showmanual)"; apt-get update; apt-get install -y --no-install-recommends gnupg; rm -rf /var/lib/apt/lists/*; mkdir -p /usr/src; cd /usr/src; curl -fsSL -o php.tar.xz "$PHP_URL"; if [ -n "$PHP_SHA256" ]; then echo "$PHP_SHA256 *php.tar.xz" | sha256sum -c -; fi; curl -fsSL -o php.tar.xz.asc "$PHP_ASC_URL"; export GNUPGHOME="$(mktemp -d)"; for key in $GPG_KEYS; do gpg --batch --keyserver keyserver.ubuntu.com --recv-keys "$key"; done; gpg --batch --verify php.tar.xz.asc php.tar.xz; gpgconf --kill all; rm -rf "$GNUPGHOME"; apt-mark auto '.*' > /dev/null; apt-mark manual $savedAptMark > /dev/null; apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false # buildkit
COPY docker-php-source /usr/local/bin/ # buildkit
RUN /bin/sh -c set -eux; savedAptMark="$(apt-mark showmanual)"; apt-get update; apt-get install -y --no-install-recommends libargon2-dev libcurl4-openssl-dev libonig-dev libreadline-dev libsodium-dev libsqlite3-dev libssl-dev libxml2-dev zlib1g-dev ; export CFLAGS="$PHP_CFLAGS" CPPFLAGS="$PHP_CPPFLAGS" LDFLAGS="$PHP_LDFLAGS" PHP_BUILD_PROVIDER='https://github.com/docker-library/php' PHP_UNAME='Linux - Docker' ; docker-php-source extract; cd /usr/src/php; gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)"; if [ ! -d /usr/include/curl ]; then ln -sT "/usr/include/$debMultiarch/curl" /usr/local/include/curl; fi; test "$PHP_INI_DIR" != "${PHP_INI_DIR%/php}"; ./configure --build="$gnuArch" --sysconfdir="${PHP_INI_DIR%/php}" --with-config-file-path="$PHP_INI_DIR" --with-config-file-scan-dir="$PHP_INI_DIR/conf.d" --enable-option-checking=fatal --with-mhash --with-pic --enable-mbstring --enable-mysqlnd --with-password-argon2 --with-sodium=shared --with-pdo-sqlite=/usr --with-sqlite3=/usr --with-curl --with-iconv --with-openssl --with-readline --with-zlib --enable-phpdbg --enable-phpdbg-readline --with-pear --with-libdir="lib/$debMultiarch" --enable-embed --enable-zts --disable-zend-signals ; make -j "$(nproc)"; find -type f -name '*.a' -delete; make install; find /usr/local -type f -perm '/0111' -exec sh -euxc ' strip --strip-all "$@" || : ' -- '{}' + ; make clean; cp -v php.ini-* "$PHP_INI_DIR/"; cd /; docker-php-source delete; apt-mark auto '.*' > /dev/null; [ -z "$savedAptMark" ] || apt-mark manual $savedAptMark; find /usr/local -type f -executable -exec ldd '{}' ';' | awk '/=>/ { so = $(NF-1); if (index(so, "/usr/local/") == 1) { next }; gsub("^/(usr/)?", "", so); printf "*%s\n", so }' | sort -u | xargs -rt dpkg-query --search | awk 'sub(":$", "", $1) { print $1 }' | sort -u | xargs -r apt-mark manual ; apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; rm -rf /var/lib/apt/lists/*; pecl update-channels; rm -rf /tmp/pear ~/.pearrc; php --version # buildkit
COPY docker-php-ext-* docker-php-entrypoint /usr/local/bin/ # buildkit
RUN /bin/sh -c docker-php-ext-enable opcache # buildkit
RUN /bin/sh -c docker-php-ext-enable sodium # buildkit
ENTRYPOINT ["docker-php-entrypoint"]
CMD ["php" "-a"]
WORKDIR /app
RUN /bin/sh -c apt-get update && apt-get -y --no-install-recommends install mailcap libcap2-bin && apt-get clean && rm -rf /var/lib/apt/lists/* # buildkit
RUN /bin/sh -c set -eux; mkdir -p /app/public /config/caddy /data/caddy /etc/caddy /etc/frankenphp; sed -i 's/php/frankenphp run/g' /usr/local/bin/docker-php-entrypoint; echo '<?php phpinfo();' > /app/public/index.php # buildkit
COPY caddy/frankenphp/Caddyfile /etc/caddy/Caddyfile # buildkit
RUN /bin/sh -c ln /etc/caddy/Caddyfile /etc/frankenphp/Caddyfile && curl -sSLf -o /usr/local/bin/install-php-extensions https://github.com/mlocati/docker-php-extension-installer/releases/latest/download/install-php-extensions && chmod +x /usr/local/bin/install-php-extensions # buildkit
CMD ["--config" "/etc/frankenphp/Caddyfile" "--adapter" "caddyfile"]
HEALTHCHECK &{["CMD-SHELL" "curl -f http://localhost:2019/metrics || exit 1"] "0s" "0s" "0s" "0s" '\x00'}
ENV XDG_CONFIG_HOME=/config
ENV XDG_DATA_HOME=/data
EXPOSE [80/tcp]
EXPOSE [443/tcp]
EXPOSE [443/udp]
EXPOSE [2019/tcp]
LABEL org.opencontainers.image.title=FrankenPHP
LABEL org.opencontainers.image.description=The modern PHP app server
LABEL org.opencontainers.image.url=https://frankenphp.dev
LABEL org.opencontainers.image.source=https://github.com/php/frankenphp
LABEL org.opencontainers.image.licenses=MIT
LABEL org.opencontainers.image.vendor=Kévin Dunglas
ENV GODEBUG=cgocheck=0
COPY /usr/local/lib/libwatcher* /usr/local/lib/ # buildkit
RUN /bin/sh -c apt-get install -y --no-install-recommends libstdc++6 && apt-get clean && ldconfig # buildkit
COPY /usr/local/bin/frankenphp /usr/local/bin/frankenphp # buildkit
RUN /bin/sh -c setcap cap_net_bind_service=+ep /usr/local/bin/frankenphp && frankenphp version && frankenphp build-info # buildkit
RUN /bin/sh -c apt-get update && apt-get install -y git bind9-utils mycli nodejs npm nano uuid-runtime rsync && mkdir -p /root/.ssh && ssh-keyscan github.com >> /root/.ssh/known_hosts # buildkit
RUN /bin/sh -c git config --global credential.helper store # buildkit
RUN /bin/sh -c echo "https://steve.vandeheuvel:c76556998740ff4c97ffbdb3fe17b90197e6ad00@git.brainwashed.co.za" >> /root/.git-credentials # buildkit
RUN /bin/sh -c echo "https://steve%40vdh.za.net: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@github.com" >> /root/.git-credentials # buildkit
ENV CADDYFILE_PATH=/fleetbase/Caddyfile
RUN /bin/sh -c rm -rf /tmp/fleetbase # buildkit
RUN /bin/sh -c mkdir -p /tmp/fleetbase # buildkit
RUN /bin/sh -c cd /tmp/fleetbase # buildkit
ADD https://www.random.org/cgi-bin/randbyte?nbytes=10&format=h /tmp/bustcache # buildkit
RUN /bin/sh -c git clone --branch tac --depth 1 https://git.brainwashed.co.za/tac/fleetbase.git /tmp/fleetbase # buildkit
RUN /bin/sh -c cd /tmp/fleetbase && git submodule update --init --recursive # buildkit
RUN /bin/sh -c install-php-extensions pdo_mysql gd bcmath redis intl zip gmp apcu opcache memcached imagick sockets pcntl @composer # buildkit
RUN /bin/sh -c apt-get update && apt-get install -y --no-install-recommends pkg-config libgeos-dev libgeos++-dev autoconf build-essential unzip && rm -rf /var/lib/apt/lists/* # buildkit
RUN /bin/sh -c curl -fsSL -o php-geos.zip https://github.com/libgeos/php-geos/archive/dfe1ab17b0f155cc315bc13c75689371676e02e1.zip && unzip php-geos.zip && rm php-geos.zip && cd php-geos-* && ./autogen.sh && ./configure && make -j"$(nproc)" install && docker-php-ext-enable geos && cd .. && rm -rf php-geos-* # buildkit
RUN /bin/sh -c sed -e 's/^expose_php.*/expose_php = Off/' "$PHP_INI_DIR/php.ini-production" > "$PHP_INI_DIR/php.ini" && sed -i -e 's/^upload_max_filesize.*/upload_max_filesize = 1024M/' -e 's/^post_max_size.*/post_max_size = 0/' -e 's/^memory_limit.*/memory_limit = 1024M/' "$PHP_INI_DIR/php.ini" -e 's/^max_execution_time.*/max_execution_time = 60/' "$PHP_INI_DIR/php.ini" # buildkit
RUN /bin/sh -c npm install -g chokidar pnpm ember-cli npm-cli-login # buildkit
COPY /usr/bin/ssm-parent /sbin/ssm-parent # buildkit
RUN /bin/sh -c mkdir -p ~/.pnpm # buildkit
ENV PNPM_HOME=/root/.pnpm
ENV PATH=/root/.pnpm/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
ENV LOG_CHANNEL=stdout
ENV CACHE_DRIVER=null
ENV BROADCAST_DRIVER=socketcluster
ENV QUEUE_CONNECTION=redis
ENV CONSOLE_PATH=/fleetbase/console
ENV OCTANE_SERVER=frankenphp
ENV FLEETBASE_VERSION=0.7.6
ARG ENVIRONMENT=production
ENV APP_ENV=production
ARG GITHUB_AUTH_KEY
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c mkdir -p /fleetbase # buildkit
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c chown -R www-data:www-data /fleetbase # buildkit
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c cp /tmp/fleetbase/Caddyfile $CADDYFILE_PATH # buildkit
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c chown -R www-data:www-data $CADDYFILE_PATH # buildkit
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c mkdir -p /fleetbase/api && mkdir -p /fleetbase/console && chown -R www-data:www-data /fleetbase # buildkit
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c uuidgen > /fleetbase/api/.fleetbase-id # buildkit
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c export FLEETBASE_INSTANCE_ID=$(cat /fleetbase/api/.fleetbase-id) && echo "FLEETBASE_INSTANCE_ID=$FLEETBASE_INSTANCE_ID" >> /etc/environment # buildkit
WORKDIR /fleetbase/api
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c if [ -n "$GITHUB_AUTH_KEY" ]; then echo "{\"github-oauth\": {\"github.com\": \"$GITHUB_AUTH_KEY\"}}" > auth.json; fi # buildkit
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c mkdir -p /var/www/.cache/composer && chown -R www-data:www-data /var/www/.cache/composer # buildkit
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c cp /tmp/fleetbase/api/composer.json /fleetbase/api/composer.json # buildkit
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c cp /tmp/fleetbase/api/composer.lock /fleetbase/api/composer.lock # buildkit
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c chown -R www-data:www-data /fleetbase/api/composer.json /fleetbase/api/composer.lock # buildkit
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c mkdir -p /fleetbase/packages # buildkit
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c rsync -av /tmp/fleetbase/packages/ /fleetbase/packages/ # buildkit
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c chown -R www-data:www-data /fleetbase/packages # buildkit
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c su www-data -s /bin/sh -c "composer install --no-scripts --optimize-autoloader --no-dev --no-cache" # buildkit
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c rsync -av /tmp/fleetbase/api/ /fleetbase/api/ # buildkit
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c chown -R www-data:www-data /fleetbase/api # buildkit
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c su www-data -s /bin/sh -c "composer dumpautoload" # buildkit
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c mkdir -p /root/.composer # buildkit
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c mkdir -p /fleetbase/api/.composer && chown www-data:www-data /fleetbase/api/.composer # buildkit
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c mkdir -p /fleetbase/api/storage/logs/ && touch /fleetbase/api/storage/logs/laravel-$(date +'%Y-%m-%d').log # buildkit
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c chown -R www-data:www-data /fleetbase/api/storage # buildkit
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c chmod -R 755 /fleetbase/api/storage # buildkit
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c chmod +x /fleetbase/api/deploy.sh # buildkit
RUN |2 ENVIRONMENT=production GITHUB_AUTH_KEY= /bin/sh -c rm -rf /tmp/fleetbase # buildkit

Labels

Key Value
org.opencontainers.image.created 2026-01-18T04:17:40Z
org.opencontainers.image.description The modern PHP app server
org.opencontainers.image.licenses MIT
org.opencontainers.image.revision d9ba18fd239700fab0541c372e44d99d58779285
org.opencontainers.image.source https://github.com/php/frankenphp
org.opencontainers.image.title FrankenPHP
org.opencontainers.image.url https://frankenphp.dev
org.opencontainers.image.vendor Kévin Dunglas
org.opencontainers.image.version v1.11.1
Details
Container
2026-01-21 06:26:33 +02:00
37
OCI / Docker
linux/arm64
MIT
843 MiB
Versions (14) View all
latest 2026-04-02
v1.0.8 2026-04-02
v1.0.7 2026-03-30
v1.0.6 2026-03-23
v1.0.5 2026-03-19