Sandro Bonazzola has uploaded a new change for review. Change subject: config: use .pgpass for db password ......................................................................
config: use .pgpass for db password database connection parameters read from .pgpass were all passed to the config parser as defaults with the exception of the pg_pass default. This patch set pg_pass with the value read from .pgpass if not specified by command line or config file. Change-Id: I60adef202e00cf9a49f9b512e499064ae705a4f1 Signed-off-by: Sandro Bonazzola <[email protected]> --- M src/__main__.py 1 file changed, 3 insertions(+), 1 deletion(-) git pull ssh://gerrit.ovirt.org:29418/ovirt-log-collector refs/changes/61/16061/1 diff --git a/src/__main__.py b/src/__main__.py index 0ef7278..93e3a94 100755 --- a/src/__main__.py +++ b/src/__main__.py @@ -50,7 +50,7 @@ # Default DB connection params pg_user = 'postgres' -pg_pass = '12345' +pg_pass = None pg_dbname = 'engine' pg_dbhost = 'localhost' pg_dbport = '5432' @@ -1399,6 +1399,8 @@ try: conf = Configuration(parser) + if not conf.get('pg_pass') and pg_pass: + conf['pg_pass'] = pg_pass collector = LogCollector(conf) # We must ensure that the working directory exits before -- To view, visit http://gerrit.ovirt.org/16061 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I60adef202e00cf9a49f9b512e499064ae705a4f1 Gerrit-PatchSet: 1 Gerrit-Project: ovirt-log-collector Gerrit-Branch: ovirt-log-collector-3.2 Gerrit-Owner: Sandro Bonazzola <[email protected]> _______________________________________________ Engine-patches mailing list [email protected] http://lists.ovirt.org/mailman/listinfo/engine-patches
