Skip to content

lbajsarowicz/action-version-matrix

Use this GitHub action with your project
Add this Action to an existing workflow or create a new one
View on Marketplace

Repository files navigation

Version Matrix

CI Release License: MIT

Generate Magento/Adobe Commerce CI matrix from the magento.watch API.

This GitHub Action fetches currently supported versions and their system requirements (PHP, MySQL, Elasticsearch, Redis, etc.) and outputs a ready-to-use strategy.matrix JSON — so your CI always tests against the right combinations without manual maintenance.

Features

  • Fetches live data from magento.watch API
  • Supports Magento Open Source, Adobe Commerce, and Mage-OS distributions
  • Three filtering modes: latest (one per minor line), all, or custom
  • Outputs a complete matrix including PHP, database, search, cache, and web server versions

Usage

Latest patch per minor line (default)

jobs:
  test:
    runs-on: ubuntu-latest
    strategy:
      matrix: ${{ fromJson(needs.matrix.outputs.matrix) }}
    steps:
      - run: echo "Testing Magento ${{ matrix.magento }} with PHP ${{ matrix.php }}"

  matrix:
    runs-on: ubuntu-latest
    outputs:
      matrix: ${{ steps.matrix.outputs.matrix }}
    steps:
      - uses: lbajsarowicz/action-version-matrix@v1
        id: matrix

All supported versions

- uses: lbajsarowicz/action-version-matrix@v1
  id: matrix
  with:
    kind: all

Custom versions

- uses: lbajsarowicz/action-version-matrix@v1
  id: matrix
  with:
    kind: custom
    custom_versions: '2.4.7-p4,2.4.8'

Adobe Commerce

- uses: lbajsarowicz/action-version-matrix@v1
  id: matrix
  with:
    distribution: magento-commerce

Inputs

Input Description Default
distribution API distribution: magento-community, magento-commerce, mage-os magento-community
kind latest = latest patch per minor, all = every supported patch, custom = user-specified latest
custom_versions Comma-separated versions (only when kind: custom) ''

Outputs

Output Description
matrix JSON string for strategy.matrix: ${{ fromJson(...) }}

Matrix format

Each entry in matrix.include contains:

{
  "magento": "2.4.7-p4",
  "php": "8.3",
  "composer": "2",
  "mysql": "8.0",
  "mariadb": "10.6",
  "elasticsearch": "8.11",
  "opensearch": "2.12",
  "redis": "7.2",
  "valkey": "8.0",
  "rabbitmq": "3.13",
  "varnish": "7.5",
  "nginx": "1.26"
}

Versioning

This action follows semantic versioning. Use the major version tag for stability:

- uses: lbajsarowicz/action-version-matrix@v1  # recommended
- uses: lbajsarowicz/action-version-matrix@v1.2.0  # pin exact version

License

MIT

About

Generate Magento/Adobe Commerce CI matrix from magento.watch API

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors