Skip to content

Commit

Permalink
Merge pull request #69 from CrowdStrike/FIX-ssm-action
Browse files Browse the repository at this point in the history
bugfix - action case
  • Loading branch information
kkvinjam authored Oct 21, 2024
2 parents ec58293 + 66a0dd6 commit 2f3640f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions templates/crowdstrike_init_stack.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -434,7 +434,7 @@ Resources:
- ParameterKey: SecretStorageMethod
ParameterValue: 'SecretsManager'
- ParameterKey: Action
ParameterValue: 'install'
ParameterValue: 'Install'
- ParameterKey: ScheduleExpression
ParameterValue: !Ref ScheduleExpression
- ParameterKey: MaxErrors
Expand Down Expand Up @@ -1200,14 +1200,14 @@ Resources:
print(('key = %s' %key))
s3.copy_object(CopySource=copy_source, Bucket=dest_bucket,
Key=key)
def bucket_exists():
def bucket_exists(bucket):
s3 = boto3.client('s3')
buckets = s3.list_buckets()
for bucket in buckets['Buckets']:
if bucket in buckets['Buckets']:
return True
def delete_objects(bucket, prefix, objects):
s3 = boto3.client('s3')
if bucket_exists():
if bucket_exists(bucket):
objects = {'Objects': [{'Key': prefix + o} for o in objects]}
s3.delete_objects(Bucket=bucket, Delete=objects)
def timeout(event, context):
Expand Down
2 changes: 1 addition & 1 deletion templates/ssm-association-stackset.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Parameters:
Action:
Description: Specify whether or not to install or uninstall the package.
Type: String
AllowedValues: [ "install", "uninstall"]
AllowedValues: [ "Install", "Uninstall"]
SecretStorageMethod:
Description: The method used to store the FalconClientId, FalconClientSecret, and FalconCloud for the CrowdStrike APIs.
Type: String
Expand Down

0 comments on commit 2f3640f

Please sign in to comment.