Skip to content
This repository has been archived by the owner on Feb 1, 2024. It is now read-only.

Commit

Permalink
Adding schema spy as a separate workflow. (#10)
Browse files Browse the repository at this point in the history
  • Loading branch information
mishraomp authored Dec 14, 2023
1 parent db84e65 commit 6ed8dcd
Showing 1 changed file with 52 additions and 0 deletions.
52 changes: 52 additions & 0 deletions .github/workflows/schema-spy.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: SchemaSpy

on:
workflow_dispatch:

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
generate-schema-spy:
name: Generate SchemaSpy Documentation
runs-on: ubuntu-22.04
services:
postgres:
image: postgres
env:
POSTGRES_DB: default
POSTGRES_USER: default
POSTGRES_PASSWORD: default
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
- 5432:5432
timeout-minutes: 10
steps:
- uses: actions/checkout@v4
- uses: joshuaavalon/[email protected]
name: Generate SchemaSpy docs for node backend
with:
url: jdbc:postgresql://postgres:5432/default
user: default
password: default
env:
FLYWAY_VALIDATE_MIGRATION_NAMING: true
FLYWAY_LOCATIONS: filesystem:./migrations
FLYWAY_DEFAULT_SCHEMA: "data_access"

- name: Create Output Folder
run: |
mkdir output
chmod a+rwx -R output
- name: Run Schemaspy
run: docker run --network host -v "$PWD/output:/output" schemaspy/schemaspy:6.2.4 -t pgsql -db default -host 127.0.0.1 -port 5432 -u default -p default -schemas data_access
- name: Deploy to Pages
uses: JamesIves/github-pages-deploy-action@v4
with:
folder: output
target-folder: schemaspy

0 comments on commit 6ed8dcd

Please sign in to comment.