name: pg-dump description: Run pg_dump to generate a backup author: tj-actions inputs: postgresql_version: description: 'Version of PostgreSQL. e.g 15' required: false database_url: description: 'Database URL' required: true path: description: 'Backup file output location' required: true options: description: 'Extra [options](https://www.postgresql.org/docs/current/app-pgdump.html#PG-DUMP-OPTIONS) passed to pg_dump' required: true default: '-O' runs: using: 'composite' steps: - name: Setup PostgreSQL uses: tj-actions/install-postgresql@v3 if: inputs.postgresql_version != '' with: postgresql-version: ${{ inputs.postgresql_version }} - run: | bash $GITHUB_ACTION_PATH/entrypoint.sh shell: bash env: # INPUT_ is not available in Composite run steps # https://github.community/t/input-variable-name-is-not-available-in-composite-run-steps/127611 INPUT_PATH: ${{ inputs.path }} INPUT_DATABASE_URL: ${{ inputs.database_url }} INPUT_OPTIONS: ${{ inputs.options }} branding: icon: hard-drive color: white