Avoid checking config file when performing standby clone action

Signed-off-by: Daniel Farina <daniel@heroku.com>
This commit is contained in:
Daniel Farina
2011-02-10 02:10:58 -08:00
parent ebbb7c3a47
commit da82829659

View File

@@ -264,8 +264,12 @@ main(int argc, char **argv)
} }
/* /*
* Read the configuration file: repmgr.conf * Read the configuration file: repmgr.conf, but only if we're not doing a
* STANDBY CLONE action: it is not necessary to have the configuration file
* in that case.
*/ */
if (action != STANDBY_CLONE)
{
parse_config(config_file, &config); parse_config(config_file, &config);
if (config.node == -1) if (config.node == -1)
{ {
@@ -273,6 +277,7 @@ main(int argc, char **argv)
"Check the configuration file.\n"); "Check the configuration file.\n");
exit(1); exit(1);
} }
}
keywords[2] = "user"; keywords[2] = "user";
values[2] = username; values[2] = username;