[8.9] [Cloud Security] Remove CloudFormation from manual options (#161037) (#161050)

# Backport

This will backport the following commits from `main` to `8.9`:
- [[Cloud Security] Remove CloudFormation from manual options
(#161037)](https://github.com/elastic/kibana/pull/161037)

<!--- Backport version: 8.9.7 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sqren/backport)

<!--BACKPORT [{"author":{"name":"Paulo
Henrique","email":"paulo.henrique@elastic.co"},"sourceCommit":{"committedDate":"2023-06-30T23:17:43Z","message":"[Cloud
Security] Remove CloudFormation from manual options
(#161037)","sha":"a25506c842422f56108ec19218777a860df6a04c","branchLabelMapping":{"^v8.10.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","Team:Cloud
Security","backport:prev-minor","v8.9.0","v8.10.0"],"number":161037,"url":"https://github.com/elastic/kibana/pull/161037","mergeCommit":{"message":"[Cloud
Security] Remove CloudFormation from manual options
(#161037)","sha":"a25506c842422f56108ec19218777a860df6a04c"}},"sourceBranch":"main","suggestedTargetBranches":["8.9"],"targetPullRequestStates":[{"branch":"8.9","label":"v8.9.0","labelRegex":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v8.10.0","labelRegex":"^v8.10.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/161037","number":161037,"mergeCommit":{"message":"[Cloud
Security] Remove CloudFormation from manual options
(#161037)","sha":"a25506c842422f56108ec19218777a860df6a04c"}}]}]
BACKPORT-->

Co-authored-by: Paulo Henrique <paulo.henrique@elastic.co>
This commit is contained in:
Kibana Machine 2023-06-30 20:23:02 -04:00 committed by GitHub
parent 5c6cdb6a2c
commit 7a27f80ab5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -103,10 +103,12 @@ export const getAwsCredentialsFormManualOptions = (): Array<{
value: AwsCredentialsType;
text: string;
}> => {
return Object.entries(getAwsCredentialsFormOptions()).map(([key, value]) => ({
value: key as AwsCredentialsType,
text: value.label,
}));
return Object.entries(getAwsCredentialsFormOptions())
.map(([key, value]) => ({
value: key as AwsCredentialsType,
text: value.label,
}))
.filter(({ value }) => value !== 'cloud_formation');
};
export const DEFAULT_MANUAL_AWS_CREDENTIALS_TYPE = 'assume_role';