name: SQL CI on: push env: DATABASE_URL: "postgresql://postgres:postgres@localhost/cartography" SHADOW_DATABASE_URL: "postgresql://postgres:postgres@localhost/shadow" ROOT_DATABASE_URL: "postgresql://postgres:postgres@localhost/postgres" jobs: migrate: runs-on: ubuntu-latest services: postgres: image: postgres:18 env: POSTGRES_PASSWORD: postgres POSTGRES_DB: cartography ports: - 5432:5432 options: >- --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 steps: - name: Checkout code uses: actions/checkout@v4 - name: Install Node.js uses: actions/setup-node@v4 with: cache: npm node-version-file: app/.node-version cache-dependency-path: app/package-lock.json - name: Check status run: npx graphile-migrate status --skipDatabase - name: Run migrate run: npx graphile-migrate migrate