Allow overriding start, stop and restart commands issued by repmgr

This commit introduces three new options:
  - start_command
  - stop_command
  - restart_command

If these are set, repmgr will issue the specified command instead
of the default pg_ctl commands
This commit is contained in:
Jarkko Oranen
2016-03-25 19:38:20 +02:00
committed by Martin
parent 72f9b0145a
commit d44885b330
3 changed files with 30 additions and 8 deletions

View File

@@ -62,6 +62,9 @@ typedef struct
char node_name[MAXLEN];
char promote_command[MAXLEN];
char follow_command[MAXLEN];
char stop_command[MAXLEN];
char start_command[MAXLEN];
char restart_command[MAXLEN];
char loglevel[MAXLEN];
char logfacility[MAXLEN];
char rsync_options[QUERY_STR_LEN];
@@ -87,7 +90,7 @@ typedef struct
* The following will initialize the structure with a minimal set of options;
* actual defaults are set in parse_config() before parsing the configuration file
*/
#define T_CONFIGURATION_OPTIONS_INITIALIZER { "", -1, NO_UPSTREAM_NODE, "", MANUAL_FAILOVER, -1, "", "", "", "", "", "", "", -1, -1, -1, "", "", "", "", "", 0, 0, 0, 0, "", { NULL, NULL }, { NULL, NULL } }
#define T_CONFIGURATION_OPTIONS_INITIALIZER { "", -1, NO_UPSTREAM_NODE, "", MANUAL_FAILOVER, -1, "", "", "", "", "", "", "", "", "", "", -1, -1, -1, "", "", "", "", "", 0, 0, 0, 0, "", { NULL, NULL }, {NULL, NULL} }
typedef struct ErrorListCell
{