PostgreSQL
Create PostgreSQL backup artifacts
postgresql_dump
Dumps a PostgreSQL database.
Typical Usage
host "db-host", hostname: "db.example.com"
job "db-backup" do
resource "database", name: "my-database", host: "db-host"
remotely as: "user" do
postgresql_dump user: "postgresql-user", password: "secret", login_host: "localhost"
end
end
Input resources
Resources of type database
are allowed.
Output resource
A resource of type file
.
Command options
Option | Description | |
---|---|---|
login_host | The host to log into. While this information seems redundant, it may be sometimes required to match the appropriate authentication method defined in the pg_hba.conf file. See there for more | Required: no |
user | The user account to use | Required: no |
password | The password to provide | Required: no |
sudo_as | Run the pg_dump command as another system user | Required: no |
Updated less than a minute ago