Skip to content

Mercure transport is not configurable since FrankenPHP v1.10 #870

@7-zete-7

Description

@7-zete-7

Since Mercure v0.21, it's now possible to disable deprecated transport behavior (or rather, enable it with the deprecated_transport flag) (see dunglas/mercure#1105). By default, Mercure is built with this flag.

FrankenPHP is built without the deprecated_transport flag. This causes the MERCURE_TRANSPORT_URL env to be ignored. The default transport is bolt:///bolt.db.

This behavior shouldn't affect most users. However, there are exceptions:

  • Those who used the MERCURE_TRANSPORT_URL environment variable may find that its value has no effect.

  • When running as an unprivileged user, the following container startup error will occur:

    Error: loading initial config: loading new config: loading frankenphp app module: provision frankenphp: failed to provision caddy http: loading http app module: provision http: server srv0: setting up route handlers: route 0: loading handler modules: position 0: loading module 'subroute': provision http.handlers.subroute: setting up subroutes: route 2: loading handler modules: position 2: loading module 'mercure': provision http.handlers.mercure: provision http.handlers.mercure.bolt: "": invalid transport: open bolt.db: permission denied
    

I see solutions to this problem:

I suggest the first option.

@dunglas @maxhelias

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions