Logo

Command Palette

Search for a command to run...

backups new

Creates a new database backup task for an application.

cx backups new --stack <application name> --dbtypes postgresql --frequency <schedule> --gzip <bool> --exclude-tables <table name> --run-on-replica <bool> --backup-type <type>

Options

ParameterRequired?DefaultDescription
--stack, -s <application name>YesName of your application
--dbtypes <type>NoallComma separated list of Database types which need backup tasks. (all, mysql, postgresql, mongodb, redis)
--frequency <schedule>No0 */1 * * *Frequency of backup task in cron schedule format
--keep <number>No100Number of previous backups to keep
--gzip <bool>NotrueCompress your backups with gzip
--exclude-tables <table name>NoTables that must be excluded from the backup
--run-on-replica <bool>NotrueRun backup task on replica server if available
--backup-type <type>NotextSpecify the type of backup to perform. Acceptable values are binary and text.

Examples

$ cx backups new -s mystack	--dbtypes postgresql --frequency="0 */1 * * *" --gzip true --exclude-tables my_log_table --run-on-replica false --backup-type text