Skip to content

Commit

Permalink
aws resources
Browse files Browse the repository at this point in the history
  • Loading branch information
JamesWoolfenden committed Jan 23, 2025
1 parent e63f4ac commit cdee658
Show file tree
Hide file tree
Showing 26 changed files with 346 additions and 25 deletions.
11 changes: 11 additions & 0 deletions src/aws.go
Original file line number Diff line number Diff line change
Expand Up @@ -1102,6 +1102,17 @@ var (
"aws_appmesh_virtual_node": awsAppmeshVirtualNode,
"aws_appmesh_virtual_router": awsAppmeshVirtualRouter,
"aws_appmesh_virtual_service": awsAppmeshVirtualService,
"aws_appstream_directory_config": awsAppstreamDirectoryConfig,
"aws_appstream_fleet": awsAppstreamFleet,
"aws_appstream_fleet_stack_association": awsAppstreamFleetStackAssociation,
"aws_appstream_stack": awsAppstreamStack,
"aws_appstream_user": awsAppstreamUser,
"aws_appstream_user_stack_association": awsAppstreamUserStackAssociation,
"aws_appsync_api_cache": awsAppsyncApiCache,
"aws_appsync_api_key": awsAppsyncApiKey,
"aws_appsync_datasource": awsAppsyncDatasource,
"aws_appsync_source_api_association": awsAppsyncSourceApiAssociation,
"aws_appsync_type": awsAppsyncType,
}
)

Expand Down
13 changes: 1 addition & 12 deletions src/coverage/aws.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# todo aws

Resource percentage coverage 72.49
Resource percentage coverage 74.25
Datasource percentage coverage 100.00

./resource.ps1 aws_amplify_backend_environment
Expand All @@ -13,17 +13,6 @@ Datasource percentage coverage 100.00
./resource.ps1 aws_apprunner_connection
./resource.ps1 aws_apprunner_custom_domain_association
./resource.ps1 aws_apprunner_deployment
./resource.ps1 aws_appstream_directory_config
./resource.ps1 aws_appstream_fleet
./resource.ps1 aws_appstream_fleet_stack_association
./resource.ps1 aws_appstream_stack
./resource.ps1 aws_appstream_user
./resource.ps1 aws_appstream_user_stack_association
./resource.ps1 aws_appsync_api_cache
./resource.ps1 aws_appsync_api_key
./resource.ps1 aws_appsync_datasource
./resource.ps1 aws_appsync_source_api_association
./resource.ps1 aws_appsync_type
./resource.ps1 aws_bedrock_guardrail
./resource.ps1 aws_bedrock_guardrail_version
./resource.ps1 aws_bedrockagent_agent_collaborator
Expand Down
33 changes: 33 additions & 0 deletions src/files.go
Original file line number Diff line number Diff line change
Expand Up @@ -3096,3 +3096,36 @@ var awsAppmeshVirtualRouter []byte

//go:embed mapping/aws/resource/appmesh/aws_appmesh_virtual_service.json
var awsAppmeshVirtualService []byte

//go:embed mapping/aws/resource/appstream/aws_appstream_directory_config.json
var awsAppstreamDirectoryConfig []byte

//go:embed mapping/aws/resource/appstream/aws_appstream_fleet.json
var awsAppstreamFleet []byte

//go:embed mapping/aws/resource/appstream/aws_appstream_fleet_stack_association.json
var awsAppstreamFleetStackAssociation []byte

//go:embed mapping/aws/resource/appstream/aws_appstream_stack.json
var awsAppstreamStack []byte

//go:embed mapping/aws/resource/appstream/aws_appstream_user.json
var awsAppstreamUser []byte

//go:embed mapping/aws/resource/appstream/aws_appstream_user_stack_association.json
var awsAppstreamUserStackAssociation []byte

//go:embed mapping/aws/resource/appsync/aws_appsync_api_cache.json
var awsAppsyncApiCache []byte

//go:embed mapping/aws/resource/appsync/aws_appsync_api_key.json
var awsAppsyncApiKey []byte

//go:embed mapping/aws/resource/appsync/aws_appsync_datasource.json
var awsAppsyncDatasource []byte

//go:embed mapping/aws/resource/appsync/aws_appsync_source_api_association.json
var awsAppsyncSourceApiAssociation []byte

//go:embed mapping/aws/resource/appsync/aws_appsync_type.json
var awsAppsyncType []byte
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
[
{
"apply": [
"appstream:CreateDirectoryConfig",
"appstream:DeleteDirectoryConfig",
"appstream:DeleteDirectoryConfig",
"appstream:DescribeDirectoryConfigs",
"appstream:UpdateDirectoryConfig",
"iam:CreateServiceLinkedRole",
"iam:DeleteServiceLinkedRole",
"iam:GetServiceLinkedRoleDeletionStatus"
],
"attributes": {
"tags": [
"appstream:TagResource",
"appstream:UntagResource"
]
},
"destroy": [
"appstream:CreateDirectoryConfig",
"appstream:DeleteDirectoryConfig",
"appstream:DescribeDirectoryConfigs",
"appstream:UpdateDirectoryConfig",
"iam:CreateServiceLinkedRole",
"iam:DeleteServiceLinkedRole",
"iam:GetServiceLinkedRoleDeletionStatus"
],
"modify": [
"appstream:CreateDirectoryConfig",
"appstream:DeleteDirectoryConfig",
"appstream:DescribeDirectoryConfigs",
"appstream:UpdateDirectoryConfig",
"iam:CreateServiceLinkedRole",
"iam:DeleteServiceLinkedRole",
"iam:GetServiceLinkedRoleDeletionStatus"
],
"plan": [
"appstream:CreateDirectoryConfig",
"appstream:DeleteDirectoryConfig",
"appstream:DescribeDirectoryConfigs",
"appstream:UpdateDirectoryConfig",
"iam:CreateServiceLinkedRole",
"iam:DeleteServiceLinkedRole",
"iam:GetServiceLinkedRoleDeletionStatus"
]
}
]
20 changes: 20 additions & 0 deletions src/mapping/aws/resource/appstream/aws_appstream_fleet.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
[
{
"apply": [
"appstream:DescribeFleets",
"appstream:CreateFleet",
"appstream:DeleteFleet",
"appstream:UpdateFleet",
"appstream:ListTagsForResource"
],
"attributes": {
"tags": [
"appstream:TagResource",
"appstream:UntagResource"
]
},
"destroy": [],
"modify": [],
"plan": []
}
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
[
{
"apply": [
"appstream:AssociateFleet",
"appstream:DisassociateFleet"
],
"attributes": {
"tags": [
"appstream:TagResource",
"appstream:UntagResource"
]
},
"destroy": [],
"modify": [],
"plan": []
}
]
19 changes: 19 additions & 0 deletions src/mapping/aws/resource/appstream/aws_appstream_stack.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
[
{
"apply": [
"appstream:DescribeStacks",
"appstream:CreateStack",
"appstream:DeleteStack",
"appstream:UpdateStack"
],
"attributes": {
"tags": [
"appstream:TagResource",
"appstream:UntagResource"
]
},
"destroy": [],
"modify": [],
"plan": []
}
]
18 changes: 18 additions & 0 deletions src/mapping/aws/resource/appstream/aws_appstream_user.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
[
{
"apply": [
"appstream:DescribeUsers",
"appstream:CreateUser",
"appstream:DeleteUser"
],
"attributes": {
"tags": [
"appstream:TagResource",
"appstream:UntagResource"
]
},
"destroy": [],
"modify": [],
"plan": []
}
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
[
{
"apply": [
"appstream:DescribeUserStackAssociations",
"appstream:BatchAssociateUserStack",
"appstream:BatchDisassociateUserStack"
],
"attributes": {
"tags": [
"appstream:TagResource",
"appstream:UntagResource"
]
},
"destroy": [],
"modify": [],
"plan": []
}
]
16 changes: 16 additions & 0 deletions src/mapping/aws/resource/appsync/aws_appsync_api_cache.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
[
{
"apply": [
"appsync:GetApiCache",
"appsync:CreateApiCache",
"appsync:DeleteApiCache",
"appsync:UpdateApiCache"
],
"attributes": {
"tags": []
},
"destroy": [],
"modify": [],
"plan": []
}
]
15 changes: 15 additions & 0 deletions src/mapping/aws/resource/appsync/aws_appsync_api_key.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
[
{
"apply": [
"appsync:CreateApiKey",
"appsync:DeleteApiKey",
"appsync:UpdateApiKey"
],
"attributes": {
"tags": []
},
"destroy": [],
"modify": [],
"plan": []
}
]
24 changes: 24 additions & 0 deletions src/mapping/aws/resource/appsync/aws_appsync_datasource.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
[
{
"apply": [
"appsync:CreateDataSource",
"appsync:GetDataSource",
"appsync:UpdateDataSource",
"iam:PassRole"
],
"attributes": {
"tags": []
},
"destroy": [
"appsync:DeleteDataSource",
"appsync:GetDataSource"
],
"modify": [
"appsync:UpdateDataSource",
"iam:PassRole"
],
"plan": [
"appsync:GetDataSource"
]
}
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
[
{
"apply": [
"appsync:AssociateSourceGraphqlApi",
"appsync:AssociateMergedGraphqlApi",
"appsync:UpdateSourceApiAssociation",
"appsync:GetSourceApiAssociation",
"appsync:DisassociateSourceGraphqlApi",
"appsync:DisassociateMergedGraphqlApi",
"appsync:ListSourceApiAssociations"
],
"attributes": {
"tags": []
},
"destroy": [
"appsync:GetSourceApiAssociation",
"appsync:DisassociateSourceGraphqlApi",
"appsync:DisassociateMergedGraphqlApi",
"appsync:ListSourceApiAssociations"
],
"modify": [
"appsync:UpdateSourceApiAssociation",
"appsync:GetSourceApiAssociation"
],
"plan": [
"appsync:GetSourceApiAssociation",
"appsync:ListSourceApiAssociations"
]
}
]
16 changes: 16 additions & 0 deletions src/mapping/aws/resource/appsync/aws_appsync_type.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
[
{
"apply": [
"appsync:GetType",
"appsync:CreateType",
"appsync:DeleteType",
"appsync:UpdateType"
],
"attributes": {
"tags": []
},
"destroy": [],
"modify": [],
"plan": []
}
]
9 changes: 9 additions & 0 deletions terraform/aws/backup/aws_appstream_directory_config.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
resource "aws_appstream_directory_config" "pike" {
directory_name = "NAME OF DIRECTORY"
organizational_unit_distinguished_names = ["DISTINGUISHED NAME"]

service_account_credentials {
account_name = "NAME OF ACCOUNT"
account_password = "PASSWORD OF ACCOUNT"
}
}
9 changes: 9 additions & 0 deletions terraform/aws/backup/aws_appstream_fleet.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
resource "aws_appstream_fleet" "pike" {
name = "NAME"
image_name = "Amazon-AppStream2-Sample-Image-03-11-2023"
instance_type = "stream.standard.small"

compute_capacity {
desired_instances = 1
}
}
4 changes: 4 additions & 0 deletions terraform/aws/backup/aws_appstream_fleet_stack_association.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
resource "aws_appstream_fleet_stack_association" "pike" {
fleet_name = aws_appstream_fleet.pike.name
stack_name = aws_appstream_stack.pike.name
}
3 changes: 3 additions & 0 deletions terraform/aws/backup/aws_appstream_stack.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
resource "aws_appstream_stack" "pike" {
name = "pike"
}
6 changes: 6 additions & 0 deletions terraform/aws/backup/aws_appstream_user.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
resource "aws_appstream_user" "pike" {
authentication_type = "USERPOOL"
user_name = "[email protected]"
first_name = "james"
last_name = "woolfenden"
}
5 changes: 5 additions & 0 deletions terraform/aws/backup/aws_appstream_user_stack_association.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
resource "aws_appstream_user_stack_association" "pike" {
authentication_type = aws_appstream_user.pike.authentication_type
stack_name = aws_appstream_stack.pike.name
user_name = aws_appstream_user.pike.user_name
}
1 change: 1 addition & 0 deletions terraform/aws/backup/aws_appsync_api_cache.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
resource "aws_appsync_api_cache" "pike" {}
1 change: 1 addition & 0 deletions terraform/aws/backup/aws_appsync_api_key.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
resource "aws_appsync_api_key" "pike" {}
1 change: 1 addition & 0 deletions terraform/aws/backup/aws_appsync_datasource.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
resource "aws_appsync_datasource" "pike" {}
1 change: 1 addition & 0 deletions terraform/aws/backup/aws_appsync_source_api_association.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
resource "aws_appsync_source_api_association" "pike" {}
1 change: 1 addition & 0 deletions terraform/aws/backup/aws_appsync_type.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
resource "aws_appsync_type" "pike" {}
Loading

0 comments on commit cdee658

Please sign in to comment.