Skip to content

Commit 01991ee

Browse files
finished aws docs
1 parent e27fcfc commit 01991ee

20 files changed

+92
-92
lines changed

src/content/docs/aws/services/rds.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -329,7 +329,7 @@ The [`aws_s3` extension](https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/
329329

330330
In the SQL code snippet below, we are loading the `aws_s3` extension, then use the `table_import_from_s3(..)` function to populate the data in a table `table1` from a CSV file `test.csv` stored in a local S3 bucket `mybucket1`:
331331

332-
```sql
332+
```sql lineNumbers
333333
CREATE EXTENSION IF NOT EXISTS aws_s3 CASCADE;
334334
SELECT aws_s3.table_import_from_s3(
335335
'table1', 'c1, c2, c3', '(format csv)',
@@ -339,7 +339,7 @@ SELECT aws_s3.table_import_from_s3(
339339

340340
Analogously, we can use the `query_export_to_s3(..)` extension function to export data from a table `table2` into a CSV file `test.csv` in local S3 bucket `mybucket2`:
341341

342-
```sql
342+
```sql lineNumbers
343343
CREATE EXTENSION IF NOT EXISTS aws_s3 CASCADE;
344344
SELECT aws_s3.query_export_to_s3(
345345
'SELECT * FROM table2',

src/content/docs/aws/services/s3.mdx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,7 @@ awslocal s3api create-bucket --bucket cors-bucket
181181
Next, create a JSON file with the CORS configuration.
182182
The file should have the following format:
183183

184-
```json title="cors-config.json"
184+
```json title="cors-config.json" lineNumbers
185185
{
186186
"CORSRules": [
187187
{
@@ -217,7 +217,7 @@ Your S3 bucket is configured to allow cross-origin resource sharing, and if you
217217
However, if you try to access your bucket from [LocalStack Web Application](https://app.localstack.cloud), you'll see errors, and your bucket won't be accessible anymore.
218218
We can edit the JSON file `cors-config.json` you created earlier with the following configuration and save it:
219219

220-
```json title="cors-config.json"
220+
```json title="cors-config.json" lineNumbers
221221
{
222222
"CORSRules": [
223223
{
@@ -263,7 +263,7 @@ IMAGE_NAME=localstack/localstack:s3-latest localstack start
263263
```
264264
</TabItem>
265265
<TabItem label="Docker Compose">
266-
```yaml
266+
```yaml lineNumbers
267267
services:
268268
localstack:
269269
container_name: "${LOCALSTACK_DOCKER_NAME:-localstack-main}"

src/content/docs/aws/services/servicediscovery.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ awslocal ecs create-cluster \
8282
Next, you will register a task definition that's compatible with Fargate.
8383
Create a file named `fargate-task.json` and add the following content:
8484

85-
```json title="fargate-task.json"
85+
```json title="fargate-task.json" lineNumbers
8686
{
8787
"family": "tutorial-task-def",
8888
"networkMode": "awsvpc",
@@ -157,7 +157,7 @@ Make a note of the `GroupId` and `SubnetId` values.
157157

158158
Create a new file named `ecs-service-discovery.json` and add the following content to it:
159159

160-
```json title="ecs-service-discovery.json"
160+
```json title="ecs-service-discovery.json" lineNumbers
161161
{
162162
"cluster": "tutorial",
163163
"serviceName": "ecs-service-discovery",

src/content/docs/aws/services/sqs.mdx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -408,7 +408,7 @@ curl "http://localhost.localstack.cloud:4566/_aws/sqs/messages?QueueUrl=http://s
408408
```
409409
</TabItem>
410410
<TabItem label="Python Requests">
411-
```python
411+
```python lineNumbers
412412
import requests
413413

414414
response = requests.get(
@@ -577,7 +577,7 @@ aws --endpoint-url=http://localhost.localstack.cloud:4566/_aws/sqs/messages sqs
577577
```
578578
</TabItem>
579579
<TabItem label="Boto3">
580-
```python
580+
```python lineNumbers
581581
import boto3
582582
sqs = boto3.client("sqs", endpoint_url="http://localhost.localstack.cloud:4566/_aws/sqs/messages")
583583
response = sqs.receive_message(QueueUrl="http://sqs.us-east-1.localhost.localstack.cloud:4566/000000000000/my-queue")
@@ -631,7 +631,7 @@ curl -H "Accept: application/json" \
631631
```
632632
</TabItem>
633633
<TabItem label="Python Requests">
634-
```python
634+
```python lineNumbers
635635
import requests
636636
response = requests.get(
637637
"http://localhost.localstack.cloud:4566/_aws/sqs/messages",

src/content/docs/aws/services/stepfunctions.mdx

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ You can create a state machine using the [`CreateStateMachine`](https://docs.aws
2828
The API requires the name of the state machine, the state machine definition, and the role ARN that the state machine will assume to call AWS services.
2929
Run the following command to create a state machine:
3030

31-
```bash
31+
```bash lineNumbers
3232
awslocal stepfunctions create-state-machine \
3333
--name "CreateAndListBuckets" \
3434
--definition '{
@@ -167,7 +167,7 @@ The first step is to select the state machine where mocked responses should be a
167167

168168
In this example, we'll use a state machine named `LambdaSQSIntegration`, defined as follows:
169169

170-
```json title="LambdaSQSIntegration.json"
170+
```json title="LambdaSQSIntegration.json" lineNumbers
171171
{
172172
"Comment": "This state machine is called: LambdaSQSIntegration",
173173
"QueryLanguage": "JSONata",
@@ -223,7 +223,7 @@ This section specifies the Step Functions state machines to mock, along with the
223223

224224
Each test case maps state names to `ResponseID`s defined in the `MockedResponses` section.
225225

226-
```json
226+
```json lineNumbers
227227
"StateMachines": {
228228
"<StateMachineName>": {
229229
"TestCases": {
@@ -247,7 +247,7 @@ At runtime, if a test case is selected, the state uses the mocked response (if d
247247

248248
Below is a complete example of the `StateMachines` section:
249249

250-
```json
250+
```json lineNumbers
251251
"LambdaSQSIntegration": {
252252
"TestCases": {
253253
"LambdaRetryCase": {
@@ -264,7 +264,7 @@ This section defines mocked responses for Task states.
264264

265265
Each `ResponseID` includes one or more step keys and defines either a `Return` value or a `Throw` error.
266266

267-
```json
267+
```json lineNumbers
268268
"MockedResponses": {
269269
"<ResponseID>": {
270270
"<step-key>": { "Return": ... },
@@ -287,7 +287,7 @@ Each entry must have **either** `Return` or `Throw`, but cannot have both.
287287

288288
Here is a complete example of the `MockedResponses` section:
289289

290-
```json
290+
```json lineNumbers
291291
"MockedLambdaStateRetry": {
292292
"0": {
293293
"Throw": {
@@ -314,7 +314,7 @@ Here is a complete example of the `MockedResponses` section:
314314

315315
The `MockConfigFile.json` below is used to test the `LambdaSQSIntegration` state machine defined earlier.
316316

317-
```json
317+
```json lineNumbers
318318
{
319319
"StateMachines":{
320320
"LambdaSQSIntegration":{
@@ -394,7 +394,7 @@ localstack start --volume /path/to/MockConfigFile.json:/tmp/MockConfigFile.json
394394
```
395395
</TabItem>
396396
<TabItem label="Docker Compose">
397-
```yaml
397+
```yaml lineNumbers
398398
services:
399399
localstack:
400400
container_name: "${LOCALSTACK_DOCKER_NAME:-localstack-main}"
@@ -452,7 +452,7 @@ awslocal stepfunctions describe-execution \
452452
--execution-arn "arn:aws:states:us-east-1:000000000000:execution:LambdaSQSIntegration:MockExecutionBaseCase"
453453
```
454454

455-
```json
455+
```json lineNumbers
456456
{
457457
"executionArn": "arn:aws:states:us-east-1:000000000000:execution:LambdaSQSIntegration:MockExecutionBaseCase",
458458
"stateMachineArn": "arn:aws:states:us-east-1:000000000000:stateMachine:LambdaSQSIntegration",

src/content/docs/aws/services/swf.mdx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ awslocal swf list-domains --registration-status DEPRECATED
8282
You can register a workflow using the [`RegisterWorkflowType`](https://docs.aws.amazon.com/amazonswf/latest/apireference/API_RegisterWorkflowType.html) API.
8383
Execute the following command to register a workflow named `test-workflow`:
8484

85-
```bash
85+
```bash lineNumbers
8686
awslocal swf register-workflow-type \
8787
--domain test-domain \
8888
--name test-workflow \
@@ -130,7 +130,7 @@ The following output would be retrieved:
130130
You can register an activity using the [`RegisterActivityType`](https://docs.aws.amazon.com/amazonswf/latest/apireference/API_RegisterActivityType.html) API.
131131
Execute the following command to register an activity named `test-activity`:
132132

133-
```bash
133+
```bash lineNumbers
134134
awslocal swf register-activity-type \
135135
--domain test-domain \
136136
--name test-activity \
@@ -145,7 +145,7 @@ awslocal swf register-activity-type \
145145
You can use the [`DescribeActivityType`](https://docs.aws.amazon.com/amazonswf/latest/apireference/API_DescribeActivityType.html) API to verify that the activity was registered successfully.
146146
Run the following command to describe the `test-activity` activity:
147147

148-
```bash
148+
```bash lineNumbers
149149
awslocal swf describe-activity-type \
150150
--domain test-domain \
151151
--activity-type name=test-activity,version=1.0
@@ -180,7 +180,7 @@ The following output would be retrieved:
180180
You can start a workflow execution using the [`StartWorkflowExecution`](https://docs.aws.amazon.com/amazonswf/latest/apireference/API_StartWorkflowExecution.html) API.
181181
Execute the following command to start a workflow execution for the `test-workflow` workflow:
182182

183-
```bash
183+
```bash lineNumbers
184184
awslocal swf start-workflow-execution \
185185
--domain test-domain \
186186
--workflow-type name=test-workflow,version=1.0 \

src/content/docs/aws/services/transfer.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ Whether you're looking to facilitate file transfers or enhance your data access
1717

1818
This Python code demonstrates a basic workflow for transferring a file between a local machine and AWS S3 using the AWS Transfer Family service and FTP (File Transfer Protocol).
1919

20-
```python
20+
```python lineNumbers
2121
import io
2222
import time
2323
import uuid

src/content/docs/aws/services/verifiedpermissions.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ To create a Verified Permissions Policy, use the [`CreatePolicy`](https://docs.a
5555

5656
Create a JSON file named `static_policy.json` with the following content:
5757

58-
```json
58+
```json lineNumbers
5959
{
6060
"static": {
6161
"description": "Grant the User alice access to view the trip Album",

src/content/docs/aws/services/waf.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ We will walk you through creating, listing, tagging, and viewing tags for Web Ac
2626
Start by creating a Web Access Control List (WebACL) using the [`CreateWebACL`](https://docs.aws.amazon.com/waf/latest/APIReference/API_CreateWebACL.html) API.
2727
Run the following command to create a WebACL named `TestWebAcl`:
2828

29-
```bash
29+
```bash lineNumbers
3030
awslocal wafv2 create-web-acl \
3131
--name TestWebAcl \
3232
--scope REGIONAL \

src/content/docs/aws/services/xray.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ You can generates a unique trace ID and constructs a JSON document with trace in
4242
It then sends this trace segment to the AWS X-Ray API using the [PutTraceSegments](https://docs.aws.amazon.com/xray/latest/api/API_PutTraceSegments.html) API.
4343
Run the following commands in your terminal:
4444

45-
```bash
45+
```bash lineNumbers
4646
START_TIME=$(date +%s)
4747
HEX_TIME=$(printf '%x\n' $START_TIME)
4848
GUID=$(dd if=/dev/random bs=12 count=1 2>/dev/null | od -An -tx1 | tr -d ' \t\n')
@@ -68,7 +68,7 @@ Sending trace segment to X-Ray API: {"trace_id": "1-6501ee11-056ec85fafff21f648e
6868
You can now retrieve the trace summaries from the last 10 minutes using the [GetTraceSummaries](https://docs.aws.amazon.com/xray/latest/api/API_GetTraceSummaries.html) API.
6969
Run the following commands in your terminal:
7070

71-
```bash
71+
```bash lineNumbers
7272
EPOCH=$(date +%s)
7373
awslocal xray get-trace-summaries --start-time $(($EPOCH-600)) --end-time $(($EPOCH))
7474
{

0 commit comments

Comments
 (0)