diff --git a/action.yaml b/action.yaml index 191db57..76e6890 100644 --- a/action.yaml +++ b/action.yaml @@ -13,7 +13,8 @@ inputs: runs: using: "composite" steps: - - name: Postgres15 + - name: Postgres15 + shell: bash run: | sudo apt-get remove postgresql-client-common sudo sh -c 'echo "deb http://apt.postgresql.org/pub/repos/apt $(lsb_release -cs)-pgdg main" > /etc/apt/sources.list.d/pgdg.list' @@ -21,17 +22,16 @@ runs: sudo apt update sudo apt install postgresql-15 postgresql-client-15 -y /usr/lib/postgresql/15/bin/pg_dump --clean --if-exists --quote-all-identifiers --schema '*' --exclude-schema 'extensions|graphql|graphql_public|net|pgbouncer|pgsodium|pgsodium_masks|realtime|supabase_functions|storage|pg_*|information_schema' -d postgres://postgres:${{ supabase_url }}@${{ supabase_password }}:6543/postgres > dump.sql - shell: bash - + - name: Tweaking the dump file + shell: bash run: | sed -i -e 's/^DROP SCHEMA IF EXISTS "auth";$/-- DROP SCHEMA IF EXISTS "auth";/' dump.sql sed -i -e 's/^DROP SCHEMA IF EXISTS "storage";$/-- DROP SCHEMA IF EXISTS "storage";/' dump.sql sed -i -e 's/^CREATE SCHEMA "auth";$/-- CREATE SCHEMA "auth";/' dump.sql sed -i -e 's/^CREATE SCHEMA "storage";$/-- CREATE SCHEMA "storage";/' dump.sql sed -i -e 's/^ALTER DEFAULT PRIVILEGES FOR ROLE "supabase_admin"/-- ALTER DEFAULT PRIVILEGES FOR ROLE "supabase_admin"/' dump.sql - shell: bash - + branding: icon: database color: green