-
Notifications
You must be signed in to change notification settings - Fork 412
Open
Labels
bugSomething isn't workingSomething isn't working
Description
What happened?
Using the Docker image. When upgrading from 1.9 to .10 a new file called bolt.db is created at the root of the project. The file isn't created with 1.9.
What is it, and how can I prevent this file from being generated?
My Caddyfile is mounted over the FrankenPHP one:
services:
php:
build:
target: frankenphp_dev
volumes:
- './config/docker/Caddyfile:/etc/frankenphp/Caddyfile'
{
skip_install_trust
{$CADDY_GLOBAL_OPTIONS}
frankenphp {
{$FRANKENPHP_CONFIG}
}
}
{$CADDY_EXTRA_CONFIG}
{$SERVER_NAME:localhost} {
log {
{$CADDY_SERVER_LOG_OPTIONS}
# Redact the authorization query parameter that can be set by Mercure
format filter {
request>uri query {
replace authorization REDACTED
}
}
}
root /app/public
encode zstd br gzip
mercure {
# Transport to use (default to Bolt)
transport_url {$MERCURE_TRANSPORT_URL:bolt:///data/mercure.db}
# Publisher JWT key
publisher_jwt {env.MERCURE_PUBLISHER_JWT_KEY} {env.MERCURE_PUBLISHER_JWT_ALG}
# Subscriber JWT key
subscriber_jwt {env.MERCURE_SUBSCRIBER_JWT_KEY} {env.MERCURE_SUBSCRIBER_JWT_ALG}
# Allow anonymous subscribers (double-check that it's what you want)
anonymous
# Enable the subscription API (double-check that it's what you want)
subscriptions
# Extra directives
{$MERCURE_EXTRA_DIRECTIVES}
}
{$CADDY_SERVER_EXTRA_DIRECTIVES}
# Disable Topics tracking if not enabled explicitly: https://github.com/jkarlin/topics
header ?Permissions-Policy "browsing-topics=()"
@phpRoute {
not path /.well-known/mercure*
not file {path}
}
rewrite @phpRoute index.php
@frontController path index.php
php @frontController
file_server {
precompressed zstd br gzip
hide *.php
}
}My Dockerfile:
ARG FRANKENPHP_TAG=latest
# Franken base stage
################################################################################
FROM dunglas/frankenphp:1.10-$FRANKENPHP_TAG AS frankenphp_base
SHELL ["/bin/bash", "-euxo", "pipefail", "-c"]
ARG NODE_VERSION=
ENV COMPOSER_ALLOW_SUPERUSER=1
RUN \
# Install OS packages
apt-get update; \
apt-get -y --no-install-recommends install \
brotli \
libnss3-tools \
supervisor \
unzip \
zstd \
; \
# Configure OS
sed -i '/^exec "\$@"/i if [ "$1" = "frankenphp" ] && [ "$APP_ENV" = "prod" ] && php bin/console --raw | grep -q "^doctrine:migrations:migrate"; then\n php bin/console doctrine:migrations:migrate --allow-no-migration --no-interaction --no-ansi\nfi\n' /usr/local/bin/docker-php-entrypoint; \
sed -i '/\[supervisord\]/a user=root' /etc/supervisor/supervisord.conf; \
sed -i '/\[supervisord\]/a nodaemon=true' /etc/supervisor/supervisord.conf; \
# Install PHP extensions
install-php-extensions \
@composer \
apcu \
bcmath \
calendar \
gd \
intl \
opcache \
pdo_mysql \
redis \
xsl \
zip \
; \
# Configure PHP
{ \
echo apc.enable_cli = 1; \
echo memory_limit = 256M; \
echo opcache.interned_strings_buffer = 16; \
echo opcache.max_accelerated_files = 20000; \
echo opcache.memory_consumption = 256; \
echo realpath_cache_ttl = 600; \
echo session.use_strict_mode = 1; \
echo zend.detect_unicode = 0; \
} >> "$PHP_INI_DIR/conf.d/10-php.ini"; \
# Install Node.js
if [ -n "$NODE_VERSION" ]; then \
curl -fsSL "https://deb.nodesource.com/setup_$NODE_VERSION.x" | bash -; \
apt-get install -y --no-install-recommends nodejs; \
npm install -g yarn; \
fi; \
# Cleanup
apt-get clean; \
rm -rf /var/lib/apt/lists/*
# Franken dev stage
################################################################################
FROM frankenphp_base AS frankenphp_dev
SHELL ["/bin/bash", "-euxo", "pipefail", "-c"]
RUN \
# Install OS packages
apt-get update; \
apt-get -y --no-install-recommends install \
git \
gnupg2 \
openssh-client \
; \
# Configure OS
mkdir -p ~/.ssh \
chmod 700 ~/.ssh; \
echo -e "Host *\n StrictHostKeyChecking no\n UserKnownHostsFile=/dev/null" > ~/.ssh/config; \
chmod 600 ~/.ssh/config; \
# Configure PHP
cp "$PHP_INI_DIR/php.ini-development" "$PHP_INI_DIR/php.ini"; \
{ \
echo xdebug.client_host = host.docker.internal; \
} >> "$PHP_INI_DIR/conf.d/10-php.ini"; \
# Cleanup
apt-get clean; \
rm -rf /var/lib/apt/lists/*Build Type
Docker (Debian Trixie)
Worker Mode
Yes
Operating System
GNU/Linux
CPU Architecture
x86_64
PHP configuration
Not relevantRelevant log output
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working