Comment 45 for bug 1658821

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : A change has been merged

Reviewed: https://review.opencontrail.org/29110
Committed: http://github.org/Juniper/contrail-controller/commit/a07d54afbc3ab369e39676f861b4c40cc351cef7
Submitter: Zuul (<email address hidden>)
Branch: master

commit a07d54afbc3ab369e39676f861b4c40cc351cef7
Author: zcui <email address hidden>
Date: Tue Feb 21 14:33:24 2017 -0800

Requirement: add admin_user/admin_password conf file

Description:
Customer require a way to read admin/admin password from given path/file
--admin-user and --admin-password command is not secret since it would be displayed.The expected change to contrail-logs, contrail-stats, contrail-flow.
Solution:
Add a new command --admin-conf-file and follow these rules:
(1) giving the highest priority to --admin/--admin-password only when they are specified in the command line.
(2) if --admin/--admin-password are not specified and --conf-file is specified, read the file specified by --conf-file.
(3) if any of --admin/--admin-password/--conf-file are not specified, read the default conf file.
(4) if any options are not specified and the credential cannot be read from the default conf file, use default user and password.

Closes-Bug: 1658821

Conflicts:
 src/opserver/log.py

Change-Id: I7b4fbc0dd5f06fe6b740d6f3251839f26116627d