You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+38-2Lines changed: 38 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -89,7 +89,13 @@ The policy attattched to this role must have at least these permissions:
89
89
"iam:PassRole",
90
90
"logs:CreateLogGroup",
91
91
"logs:GetLogEvents",
92
-
"s3:*"
92
+
"s3:*",
93
+
"ec2:DescribeSecurityGroups",
94
+
"ec2:DescribeSecurityGroupRules",
95
+
"ec2:AuthorizeSecurityGroupEgress",
96
+
"ec2:CreateSecurityGroup",
97
+
"ec2:AuthorizeSecurityGroupIngress",
98
+
"ec2:DeleteSecurityGroup"
93
99
],
94
100
"Resource": "*"
95
101
},
@@ -111,6 +117,36 @@ The policy attattched to this role must have at least these permissions:
111
117
```
112
118
### Usage in your workflow
113
119
120
+
#### Easiest way to get started
121
+
122
+
123
+
```yaml
124
+
jobs:
125
+
terraform:
126
+
runs-on: ubuntu-latest
127
+
permissions:
128
+
contents: read
129
+
id-token: write
130
+
steps:
131
+
- uses: actions/checkout@v3
132
+
133
+
- uses: sonikro/aws-run@v1
134
+
with:
135
+
role_arn: "${{secrets.ROLE_ARN}}"
136
+
image: hashicorp/terraform:latest
137
+
region: us-east-1
138
+
vpc_id: "${{secrets.VPC_ID}}"
139
+
subnet_ids: |
140
+
${{secrets.SUBNBET_ID}}
141
+
shell: sh
142
+
run: |
143
+
terraform apply
144
+
```
145
+
146
+
#### Specifying a custom security group id
147
+
148
+
If you don't want the action to create a temporary security-group for the remote execution (the security group blocks all incoming traffic and allows all outgoing traffic), you must specify the **security_group_id** argument
149
+
114
150
```yaml
115
151
jobs:
116
152
terraform:
@@ -177,7 +213,7 @@ In the execution phase, the action will:
177
213
- [X] Delete the Cloudwatch Logstream on Teardown
178
214
- [X] Allow multiple Subnet IDs
179
215
- [X] Stream the Cloudwatch logs as they happen, and not just at the end of the execution
180
-
- [] Automatically create temporary security group if one is not provided
216
+
- [X] Automatically create temporary security group if one is not provided
181
217
- [ ] Automatically grab list of Subnets for VPC_ID, if Subnet_IDS are not provided
182
218
- [ ] Mask secrets inside the Cloudwatch Logs
183
219
- [X] Map all GitHub Contexts/ENVS into the ECS Container
0 commit comments