Skip to content

mw app create php|node|python: allow pinning the system-software (runtime) version at creation #1951

Description

@Hermsi1337

Summary

mw app create php (and the Node.js / Python equivalents) offer no way to choose the runtime / system-software version. The newest available version is assigned by default, and there's no flag to change that at creation time.

Why this is a problem

For migrations and version-sensitive apps this bites. Example: Shopware 6.6 supports PHP 8.1–8.3, but mw app create php provisions the newest available PHP (8.5 at the time of writing), so the app won't start. Today the only path is a second call after creation:

mw app create php -p <project> --document-root /public
mw app dependency update <installationId> --set php=~8.3

The capability exists — mw app dependency update, and the API how-to "Change the version of a system software" — it just isn't reachable at create time. The documented POST /v2/projects/{projectId}/app-installations body only accepts appVersionId / description / updatePolicy (no systemSoftware), so the version genuinely can't be pinned in one step today; it's create-then-update.

Proposed solution

Add a way to pin the system-software version on mw app create php|node|python, e.g. a --set <dependency>=<version> flag mirroring mw app dependency update (or a dedicated --php-version / --node-version). The command could perform create + dependency-update internally (or pass systemSoftware straight through if/when the create endpoint starts accepting it).

Impact

Removes an easy-to-miss second step. An app provisioned on the wrong major (e.g. PHP 8.5 for a PHP 8.1–8.3 app) fails to start, which is confusing for users who reasonably assume create would honour a chosen version.

CLI version: 1.18.0.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions