mirror of
https://github.com/rommapp/romm.git
synced 2026-11-30 18:42:34 +01:00
GitHub is deprecating the Node 20 action runtime. Every third-party action in the workflows was still pinned to a Node 20 release, so each is moved to its latest release, all of which declare `runs.using: node24`: - actions/checkout v4.3.x -> v7.0.1 - astral-sh/setup-uv v6.7.0 -> v10.0.1 - docker/login-action v3.5.0 -> v4.6.0 - docker/metadata-action v5.8.0 -> v6.2.0 - docker/build-push-action v6.18.0 -> v7.3.0 - docker/setup-qemu-action v3.6.0 -> v4.3.0 - docker/setup-buildx-action v3.11.1 -> v4.3.0 - actions/github-script v7.1.0 -> v9.0.0 - actions/upload-artifact v4.6.2 -> v7.0.1 - peter-evans/create-pull-request v7.0.11 -> v8.1.1 - trunk-io/trunk-action v1.2.4 -> v2.0.0 (its nested actions were on Node 20) actions/setup-node and actions/setup-python were already on Node 24 but are bumped to v7.0.0 as well, and the setup-node reference in the trunk setup-ci composite action is now SHA-pinned like the rest. None of the removed inputs, deprecated envs, or event-specific behavior changes in the crossed major versions are used by these workflows. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
111 lines
2.9 KiB
YAML
111 lines
2.9 KiB
YAML
name: Run Migrations
|
|
|
|
on:
|
|
pull_request:
|
|
paths:
|
|
- "backend/alembic/versions/**"
|
|
|
|
permissions: read-all
|
|
|
|
jobs:
|
|
migrate-postgres:
|
|
runs-on: ubuntu-latest
|
|
permissions:
|
|
checks: write
|
|
pull-requests: write
|
|
services:
|
|
postgres:
|
|
image: postgres:15
|
|
env:
|
|
POSTGRES_USER: user
|
|
POSTGRES_PASSWORD: password
|
|
POSTGRES_DB: testdb
|
|
ports:
|
|
- 5432:5432
|
|
options: >-
|
|
--health-cmd pg_isready
|
|
--health-interval 10s
|
|
--health-timeout 5s
|
|
--health-retries 5
|
|
steps:
|
|
- name: Checkout code
|
|
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
|
|
- name: Install mariadb connectors
|
|
run: |
|
|
sudo apt-get update
|
|
sudo apt-get install -y libmariadb3 libmariadb-dev
|
|
|
|
- name: Install uv
|
|
uses: astral-sh/setup-uv@20cfd1bf945f4377ade1205e4dbc17946fc9a30d # v10.0.1
|
|
|
|
- name: Install python
|
|
run: uv python install 3.13
|
|
|
|
- name: Install dependencies
|
|
run: uv sync
|
|
|
|
- name: Run PostgreSQL Migrations
|
|
working-directory: backend
|
|
env:
|
|
ROMM_DB_DRIVER: postgresql
|
|
DB_HOST: localhost
|
|
DB_PORT: 5432
|
|
DB_USER: user
|
|
DB_PASSWD: password
|
|
DB_NAME: testdb
|
|
ROMM_AUTH_SECRET_KEY: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
|
|
ROMM_BASE_PATH: romm_test
|
|
run: uv run alembic upgrade head
|
|
|
|
migrate-mariadb:
|
|
runs-on: ubuntu-latest
|
|
permissions:
|
|
checks: write
|
|
pull-requests: write
|
|
services:
|
|
mariadb:
|
|
image: mariadb:10.11
|
|
env:
|
|
MARIADB_USER: user
|
|
MARIADB_PASSWORD: password
|
|
MARIADB_DATABASE: testdb
|
|
MARIADB_ROOT_PASSWORD: root
|
|
ports:
|
|
- 3306:3306
|
|
options: >-
|
|
--health-cmd "mysqladmin ping -h 127.0.0.1 -u root --password=root"
|
|
--health-interval 10s
|
|
--health-timeout 5s
|
|
--health-retries 5
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
|
|
- name: Install mariadb connectors
|
|
run: |
|
|
sudo apt-get update
|
|
sudo apt-get install -y libmariadb3 libmariadb-dev
|
|
|
|
- name: Install uv
|
|
uses: astral-sh/setup-uv@20cfd1bf945f4377ade1205e4dbc17946fc9a30d # v10.0.1
|
|
|
|
- name: Install python
|
|
run: uv python install 3.13
|
|
|
|
- name: Install dependencies
|
|
run: uv sync
|
|
|
|
- name: Run MariaDB Migrations
|
|
working-directory: backend
|
|
env:
|
|
ROMM_DB_DRIVER: mariadb
|
|
DB_HOST: 127.0.0.1
|
|
DB_PORT: 3306
|
|
DB_USER: user
|
|
DB_PASSWD: password
|
|
DB_NAME: testdb
|
|
ROMM_AUTH_SECRET_KEY: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
|
|
ROMM_BASE_PATH: romm_test
|
|
run: uv run alembic upgrade head
|