Skip to content

Commit

Permalink
[pr] feedback from #520
Browse files Browse the repository at this point in the history
  • Loading branch information
Jack Naglieri committed Dec 12, 2017
1 parent 08adbd3 commit 3a4b2f9
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 6 deletions.
8 changes: 5 additions & 3 deletions manage.py
Original file line number Diff line number Diff line change
Expand Up @@ -977,7 +977,7 @@ def _add_default_lambda_args(lambda_parser):
required=True)

lambda_parser.add_argument(
'--cluster',
'--clusters',
help=ARGPARSE_SUPPRESS,
nargs='+')

Expand Down Expand Up @@ -1007,7 +1007,7 @@ def _add_terraform_subparser(subparsers):
--target The Terraform module name to apply.
Valid options: stream_alert, kinesis, kinesis_events,
cloudtrail, monitoring, and s3_events.
--cluster The StreamAlert cluster(s) to apply to.
--clusters The StreamAlert cluster(s) to apply to.
Examples:
Expand Down Expand Up @@ -1049,7 +1049,9 @@ def _add_terraform_subparser(subparsers):
nargs='+')

tf_parser.add_argument(
'--cluster',
'--clusters',
action=UniqueSetAction,
default=set(),
help=ARGPARSE_SUPPRESS,
nargs='+')

Expand Down
2 changes: 1 addition & 1 deletion stream_alert_cli/manage_lambda/deploy.py
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ def deploy(options, config):
processors = options.processor

for processor in processors:
package, targets = _create_and_upload(processor, config, options.cluster)
package, targets = _create_and_upload(processor, config, options.clusters)
# Continue if the package isn't enabled
if not all([package, targets]):
continue
Expand Down
4 changes: 2 additions & 2 deletions stream_alert_cli/terraform/handler.py
Original file line number Diff line number Diff line change
Expand Up @@ -162,14 +162,14 @@ def terraform_build(options, config):
'athena': 'module.stream_alert_athena',
'threat_intel_downloader': 'module.threat_intel_downloader'
}
clusters = set(options.cluster or config.clusters())
clusters = set(options.clusters or config.clusters())

if options.target:
tf_runner_targets.update({
'module.{}_{}'.format(target, cluster)
for cluster in clusters for target in options.target
})
for name, _ in custom_module_mapping.iteritems():
for name in custom_module_mapping:
if name in options.target:
tf_runner_targets.add(custom_module_mapping[name])

Expand Down

0 comments on commit 3a4b2f9

Please sign in to comment.