Open
Description
When using this as CI, sometimes you want a matrix of different PHP versions to test against. To do this at the moment you need to disable autostart, set the version, and then manually start, e.g.
- uses: ddev/github-action-setup-ddev@v1
with:
autostart: false
- name: Setup PHP Version
run: ddev config --php-version ${{ matrix.php }}
- name: Start ddev
run: ddev start
It would be nicer DX if we could just say
- uses: ddev/github-action-setup-ddev@v1
with:
php-version: ${{ matrix.php }}
Reacted by Andreas Hennings
Metadata
Metadata
Assignees
Labels
No labels
Activity
alexpott commentedon Jul 4, 2024
Maybe it should be more flexible something like:
Like PHP is just 1 thing you might want to vary by....
donquixote commentedon Oct 25, 2024
Or could we have a
config:key for config overrides?This would have the same structure as the
config.yamlfile.donquixote commentedon Oct 25, 2024
There could be another key for extensions.
tyler36 commentedon Sep 24, 2025
General ping to see if this is still an issue.
tomasnorre commentedon Oct 22, 2025
I like the suggestion here, I was about to suggest something similar. Today in the https://github.com/tomasnorre/crawler/ I do following.
sed -i 's/php_version: "8.1"/php_version: "${{ matrix.php }}"/g' .ddev/config.yamlas part of my GitHub Action, but that requires a
ddev restartafterwards.I have some additional wishes, as I "need" a way to define which core to test with.
Today I do following after the
ddev startBut I would like that to happen before the first
ddev startto spare some time.Of course it could all be done with some
sedcommands, but would be nice if it was sort of baked in. As this GitHub Action is used for testing in CI, it makes sense to have some flexibility in that matter from my point of view.I would be happy to help implement this.