-
Notifications
You must be signed in to change notification settings - Fork 42
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
4eee854
commit 41623e5
Showing
2 changed files
with
16 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
18 changes: 9 additions & 9 deletions
18
deploy/cloudformation/elastic-agent-direct-access-key-cspm.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,38 +1,38 @@ | ||
AWSTemplateFormatVersion: "2010-09-09" | ||
|
||
Description: Creates elastic-agent cspm user, role, and access key, and outputs the access key | ||
|
||
Parameters: {} | ||
|
||
Resources: | ||
ElasticCSPMUser: | ||
Type: "AWS::IAM::User" | ||
Type: AWS::IAM::User | ||
Properties: | ||
UserName: !Join | ||
- '-' | ||
- - 'elasticagent-user-cspm' | ||
- - elasticagent-user-cspm | ||
- !Select | ||
- 2 | ||
- !Split | ||
- / | ||
- !Ref AWS::StackId | ||
ManagedPolicyArns: | ||
- 'arn:aws:iam::aws:policy/SecurityAudit' | ||
- arn:aws:iam::aws:policy/SecurityAudit | ||
|
||
ElasticCSPMAccessKey: | ||
Type: "AWS::IAM::AccessKey" | ||
Type: AWS::IAM::AccessKey | ||
Properties: | ||
UserName: !Ref ElasticCSPMUser | ||
|
||
Outputs: | ||
AccessKeyId: | ||
Description: "Access Key ID" | ||
Description: Access Key ID | ||
Value: !Ref ElasticCSPMAccessKey | ||
Export: | ||
Name: "AccessKeyId" | ||
Name: AccessKeyId | ||
|
||
SecretAccessKey: | ||
Description: "Secret Access Key" | ||
Description: Secret Access Key | ||
Value: !GetAtt ElasticCSPMAccessKey.SecretAccessKey | ||
Export: | ||
Name: "SecretAccessKey" | ||
|
||
Name: SecretAccessKey |