Add a condition for systemd service detection in monasca_setup
Skip agent service detection if only installing plugins. This will make it possible to use monasca-setup on the environments where monasca-agent is not running as systemd service. Typical usecase is running agent on kubernetes. Change-Id: I232506e19f593b43cc011c6499242847c9bbc108
This commit is contained in:
parent
d30e12fde8
commit
a8be13bdeb
@ -57,10 +57,12 @@ def main(argv=None):
|
||||
LOG.info("Running in dry run mode, no changes will be made only"
|
||||
" reported")
|
||||
|
||||
# Detect and if possibly enable the agent service
|
||||
agent_service = detect_init(PREFIX_DIR, args.config_dir, args.log_dir,
|
||||
args.template_dir, username=args.user,
|
||||
name=args.agent_service_name)
|
||||
# Skip agent service detection if only installing plugins
|
||||
if not args.install_plugins_only:
|
||||
# Detect and if possibly enable the agent service
|
||||
agent_service = detect_init(PREFIX_DIR, args.config_dir, args.log_dir,
|
||||
args.template_dir, username=args.user,
|
||||
name=args.agent_service_name)
|
||||
|
||||
# Skip base setup if only installing plugins or running specific detection
|
||||
# plugins
|
||||
|
Loading…
x
Reference in New Issue
Block a user