Open barthisrael opened 3 months ago
Thanks for the issue.
Another idea: In repmgr you can define custom commands e.g. for starting PostgreSQL. Search for "service_start_command" in the documentation: https://www.repmgr.org/docs/current/configuration-file-service-commands.html
Perhaps we could add a new setting in barman like custom_restore_command = '/path/to/barman/bin/barman --config /path/to/config/barman.conf get-wal -P localhost %f > %p' If this setting exists barman would use the given command, if the setting is missing barman would use the existing strategy to create the restore_command.
Context
This issue has been created based on inputs provided through #881 .
With the current implementation, Barman generates recovery configuration for the user through
postgresql.auto.conf
.While the parameters inferred by Barman might fit well in most scenarios, there are cases where the user might want to override the values provided by Barman, e.g. override the default
restore_command
generated by Barman.Objective
The objective of this ticket is to provide means for the user to override recovery options when executing
barman recover
command. That way, if the users want to override any of the values provided by Barman topostgresql.auto.conf
they would be able to do that on their own risk.One idea for implementing that would be:
--pg-recovery-option
command-line argument forbarman recover
It could be specified multiple times, following the patternGUC=value
--pg-recovery-option
, replace the value that wold be set by Barman with the custom value