The missing action for MariaDB 🎉
- Simpler than containers
- Works on Linux, Mac, and Windows
- Supports different versions
Add it as a step to your workflow
- uses: ankane/setup-mariadb@v1The MariaDB version to download (if necessary) and use.
- uses: ankane/setup-mariadb@v1
with:
mariadb-version: "11.4"Currently supports
| Version | 11.4 |
10.11 |
10.6 |
10.5 |
|---|---|---|---|---|
ubuntu-24.04 |
default | ✓ | ||
ubuntu-22.04 |
default | ✓ | ✓ | |
ubuntu-20.04 |
default | ✓ | ✓ | ✓ |
macos-14 |
default | ✓ | ✓ | ✓ |
macos-13 |
default | ✓ | ✓ | ✓ |
macos-12 |
default | ✓ | ✓ | ✓ |
windows-2022 |
default | ✓ | ✓ | ✓ |
windows-2019 |
default | ✓ | ✓ | ✓ |
Test against multiple versions
strategy:
matrix:
mariadb-version: ["11.4", "10.11", "10.6"]
steps:
- uses: ankane/setup-mariadb@v1
with:
mariadb-version: ${{ matrix.mariadb-version }}The database to create, example
- uses: ankane/setup-mariadb@v1
with:
database: testdbDirectory to cache MariaDB data. Defaults to ".cache/mariadb". The downloaded file will be saved in this directory, allowing you to cache the download using the GitHub actions/cache action for instance.
Server URL to download from. Defaults to "https://dlm.mariadb.com". This replaces the default download server URL.
This helps to be independent of rate-limiting from the original server.
Get options added to the download URL. Defaults to an empty string. By setting download_getopt to "KEY=TOKEN", ?KEY=TOKEN is appended to the download URL, allowing you to block non-authorized downloads from your server.
steps:
- name: Setup MariaDB
uses: arkane/setup-mariadb@v1
with:
mariadb-version: "10.6"
database: "my_database"In this basic example, MariaDB version 10.6 is used, and a database named 'my_database' is created. The other parameters are set to their default values.
steps:
- name: Cache Files accross workflow sessions
uses: actions/cache@v4
with:
path: .cache/mariadb
# Example of a key, use a more appropriate one.
key: ${{ runner.os }}-mariadb-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-mariadb-
- name: Setup MariaDB
uses: arkane/setup-mariadb@v1
with:
mariadb-version: "10.6"
database: "my_database"
downloaddir: ".cache/mariadb"Run queries
- run: mysql -D testdb -e 'SELECT VERSION()'Everyone is encouraged to help improve this project. Here are a few ways you can help:
- Report bugs
- Fix bugs and submit pull requests
- Write, clarify, or fix documentation
- Suggest or add new features