Skip to content

Commit c85e948

Browse files
committed
callouts to containers
1 parent f34480d commit c85e948

29 files changed

+270
-239
lines changed

src/content/docs/aws/integrations/app-frameworks/spring-cloud-function.mdx

Lines changed: 20 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,10 @@ sidebar:
1111
In this guide, you will learn how to use LocalStack to test
1212
your serverless applications powered by Spring Cloud Function framework.
1313

14-
{{< callout >}}
14+
:::note
15+
1516
Some features and services described in this document may not work properly on aarch64, including Apple's M1 silicon.
16-
{{< /callout >}}
17+
:::
1718

1819
## Covered Topics
1920

@@ -117,7 +118,7 @@ To that end, we use the "Shadow Jar" plugin.
117118

118119
Here's our final `build.gradle`:
119120

120-
{{< highlight gradle "linenos=table" >}}
121+
{/* {{< highlight gradle "linenos=table" >}} */} {/* mdx-disabled */}
121122
plugins {
122123
id "java"
123124
id "org.jetbrains.kotlin.jvm" version '1.5.31'
@@ -194,7 +195,7 @@ shadowJar {
194195
}
195196

196197
assemble.dependsOn shadowJar
197-
{{< / highlight >}}
198+
{/* {/* {/* {/* {/* {/* {/* {/* {/* {/* {{< / highlight >}} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */}
198199

199200
Please note that we will be using `org.localstack.sampleproject` as a
200201
working namespace, and `org.localstack.sampleproject.Application` as an
@@ -210,18 +211,18 @@ In this project, we are following
210211
to setup up `src/main/resources/log4j2.xml` content.
211212

212213
```xml
213-
<?xml version="1.0" encoding="UTF-8"?>
214-
<Configuration packages="com.amazonaws.services.lambda.runtime.log4j2.LambdaAppender">
214+
{/* <?xml version="1.0" encoding="UTF-8"?> */} {/* mdx-disabled */}
215+
{/* <Configuration packages="com.amazonaws.services.lambda.runtime.log4j2.LambdaAppender"> */} {/* mdx-disabled */}
215216
<Appenders>
216-
<Lambda name="Lambda">
217+
{/* <Lambda name="Lambda"> */} {/* mdx-disabled */}
217218
<PatternLayout>
218219
<pattern>%d{yyyy-MM-dd HH:mm:ss} %X{AWSRequestId} %-5p %c{1}:%L - %m%n</pattern>
219220
</PatternLayout>
220221
</Lambda>
221222
</Appenders>
222223
<Loggers>
223-
<Root level="debug">
224-
<AppenderRef ref="Lambda" />
224+
{/* <Root level="debug"> */} {/* mdx-disabled */}
225+
{/* <AppenderRef ref="Lambda" /> */} {/* mdx-disabled */}
225226
</Root>
226227
</Loggers>
227228
</Configuration>
@@ -254,7 +255,7 @@ org.springframework.cloud.function.adapter.aws.FunctionInvoker::handleRequest
254255
Now our application needs an entry-class, the one we referenced earlier.
255256
Let's add it under `src/main/kotlin/org/localstack/sampleproject/Application.kt`.
256257

257-
{{< highlight kotlin "linenos=table" >}}
258+
{/* {/* {/* {/* {/* {/* {/* {/* {/* {{< highlight kotlin "linenos=table" >}} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */}
258259
package org.localstack.sampleproject
259260

260261
import org.springframework.boot.autoconfigure.SpringBootApplication
@@ -529,23 +530,23 @@ class LambdaApi : SpringBootStreamHandler() {
529530
companion object : Logger()
530531
531532
@Bean
532-
fun functionOne(): Function<Any, String> {
533+
{/* fun functionOne(): Function<Any, String> { */} {/* mdx-disabled */}
533534
return Function {
534535
LOGGER.info("calling function one")
535536
return@Function "ONE";
536537
}
537538
}
538539
539540
@Bean
540-
fun functionTwo(): Function<SampleModel, SampleModel> {
541+
{/* fun functionTwo(): Function<SampleModel, SampleModel> { */} {/* mdx-disabled */}
541542
return Function {
542543
LOGGER.info("calling function two")
543544
return@Function it;
544545
}
545546
}
546547
547548
@Bean
548-
fun dynamoDbStreamHandlerExample(): Function<DynamodbEvent, Unit> {
549+
{/* fun dynamoDbStreamHandlerExample(): Function<DynamodbEvent, Unit> { */} {/* mdx-disabled */}
549550
return Function {
550551
LOGGER.info("handling DynamoDB stream event")
551552
}
@@ -569,8 +570,8 @@ The `Lambda-Events` package comes with a set of predefined wrappers that you can
569570
Check our [sample project](https://github.com/localstack/localstack-pro-samples/tree/master/sample-archive/spring-cloud-function-microservice)
570571
for usage examples.
571572
572-
{{< tabpane >}}
573-
{{< tab header="Serverless" lang="yaml" >}}
573+
{/* {{< tabpane >}} */} {/* mdx-disabled */}
574+
{/* {{< tab header="Serverless" lang="yaml" >}} */} {/* mdx-disabled */}
574575
service: localstack-sampleproject-serverless
575576
576577
provider:
@@ -620,8 +621,8 @@ functions:
620621
handler: org.localstack.sampleproject.api.LambdaApi
621622
environment:
622623
FUNCTION_NAME: functionTwo
623-
{{< /tab >}}
624-
{{< tab header="AWS CDK" lang="kotlin" >}}
624+
{/* {/* {/* {{< /tab >}} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */}
625+
{/* {{< tab header="AWS CDK" lang="kotlin" >}} */} {/* mdx-disabled */}
625626
package org.localstack.cdkstack
626627
627628
import java.util.UUID
@@ -694,7 +695,7 @@ class ApplicationStack(parent: Construct, name: String) : Stack(parent, name) {
694695
}
695696
}
696697
{{< /tab >}}
697-
{{< tab header="Terraform" lang="tf" >}}
698+
{/* {{< tab header="Terraform" lang="tf" >}} */} {/* mdx-disabled */}
698699
variable "STAGE" {
699700
type = string
700701
default = "local"
@@ -843,7 +844,7 @@ resource "aws_lambda_function" "exampleFunctionTwo" {
843844
}
844845
}
845846
{{< /tab >}}
846-
{{< /tabpane >}}
847+
{/* {{< /tabpane >}} */} {/* mdx-disabled */}
847848
848849
## Testing, Debugging and Hot Reloading
849850

src/content/docs/aws/integrations/aws-native-tools/aws-cdk.mdx

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ sidebar:
66
order: 2
77
---
88

9-
<!-- ![AWS CDK](aws-cdk-logo.svg) -->
9+
{/*<!-- ![AWS CDK](aws-cdk-logo.svg) --> */}
1010

1111
## Overview
1212

@@ -29,9 +29,10 @@ cdklocal --version
2929
# e.g. 1.65.5
3030
```
3131

32-
{{< callout >}}
32+
:::note
33+
3334
Using `cdklocal` locally (e.g. within the `node_modules` of your repo instead of globally installed) does not work at the moment for some setups, so make sure you install both `aws-cdk` and `aws-cdk-local` with the `-G` flag.
34-
{{< /callout >}}
35+
:::
3536

3637
### Usage
3738

@@ -100,7 +101,7 @@ When this lambda is executed locally from the `/tmp` folder, the package can not
100101

101102
## Other resources
102103

103-
* [Hot-reloading Lambda functions with CDK]({{< ref "user-guide/lambda-tools/hot-reloading#aws-cloud-development-kit-cdk-configuration" >}})
104+
{/* * [Hot-reloading Lambda functions with CDK]({{< ref "user-guide/lambda-tools/hot-reloading#aws-cloud-development-kit-cdk-configuration" >}}) */} {/* mdx-disabled */}
104105

105106
## External resources
106107

src/content/docs/aws/integrations/aws-native-tools/aws-cli.mdx

Lines changed: 17 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,12 @@ sidebar:
99
## Introduction
1010

1111
The [AWS Command Line Interface (CLI)](https://aws.amazon.com/cli/) is a unified tool for creating and managing AWS services via a command line interface.
12-
All CLI commands applicable to services implemented within [LocalStack]({{< ref "references/coverage/" >}}) can be executed when operating against LocalStack.
12+
{/* All CLI commands applicable to services implemented within [LocalStack]({{< ref "references/coverage/" >}}) can be executed when operating against LocalStack. */} {/* mdx-disabled */}
1313

1414
You can use the AWS CLI with LocalStack using either of the following approaches:
1515

16-
* [AWS CLI]({{<ref "#aws-cli" >}})
17-
* [LocalStack AWS CLI]({{<ref "#localstack-aws-cli-awslocal">}})
16+
{/* * [AWS CLI]({{<ref "#aws-cli" >}}) */} {/* mdx-disabled */}
17+
{/* * [LocalStack AWS CLI]({{<ref "#localstack-aws-cli-awslocal">}}) */} {/* mdx-disabled */}
1818

1919
## AWS CLI
2020

@@ -31,7 +31,7 @@ You can configure the AWS CLI to redirect AWS API requests to LocalStack using t
3131

3232
### Configuring an endpoint URL
3333

34-
You can use AWS CLI with an endpoint URL by configuring test environment variables and include the `--endpoint-url=<localstack-url>` flag in your `aws` CLI commands.
34+
{/* You can use AWS CLI with an endpoint URL by configuring test environment variables and include the `--endpoint-url=<localstack-url>` flag in your `aws` CLI commands. */} {/* mdx-disabled */}
3535
For example:
3636

3737
```bash
@@ -42,9 +42,10 @@ export AWS_DEFAULT_REGION="us-east-1"
4242
aws --endpoint-url=http://localhost:4566 kinesis list-streams
4343
```
4444

45-
{{< callout >}}
45+
:::note
46+
4647
To enable the creation of pre-signed URLs for S3 buckets, please set both `AWS_ACCESS_KEY_ID` and `AWS_SECRET_ACCESS_KEY` to the value "test." Our pre-signed URL signature verification algorithm validates the pre-signed URL and its expiration.
47-
{{< /callout >}}
48+
:::
4849

4950
### Configuring a custom profile
5051

@@ -73,9 +74,10 @@ aws s3 mb s3://test --profile localstack
7374
aws s3 ls --profile localstack
7475
```
7576

76-
{{< callout "tip" >}}
77+
:::tip
78+
7779
Alternatively, you can also set the `AWS_PROFILE=localstack` environment variable, in which case the `--profile localstack` parameter can be omitted in the commands above.
78-
{{< /callout >}}
80+
:::
7981

8082
## LocalStack AWS CLI (`awslocal`)
8183

@@ -89,18 +91,20 @@ Install the `awslocal` command using the following command:
8991
pip install awscli-local[ver1]
9092
```
9193

92-
{{< callout "tip" >}}
94+
:::tip
95+
9396
The above command installs the most recent version of the underlying AWS CLI version 1 (`awscli`) package.
9497
If you would rather manage your own `awscli` version (e.g., `v1` or `v2`) and only install the wrapper script, you can use the following command:
9598

9699
```bash
97100
pip install awscli-local
98101
```
99-
{{< /callout >}}
102+
:::
103+
104+
:::note
100105

101-
{{< callout >}}
102-
Automatic installation of AWS CLI version 2 is currently not supported yet (at the time of writing there is no official pypi package for `v2` available), but the `awslocal` technically also works with AWS CLI v2 (see [this section]({{< ref "#limitations" >}}) for more details).
103-
{{< /callout >}}
106+
{/* Automatic installation of AWS CLI version 2 is currently not supported yet (at the time of writing there is no official pypi package for `v2` available), but the `awslocal` technically also works with AWS CLI v2 (see [this section]({{< ref "#limitations" >}}) for more details). */} {/* mdx-disabled */}
107+
:::
104108

105109
### Usage
106110

src/content/docs/aws/integrations/aws-native-tools/aws-copilot-cli.mdx

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -18,29 +18,29 @@ Using `copilotlocal` instead of `copilot` in your command line therefore ensures
1818

1919
### Download / Installation
2020

21-
{{< tabpane lang="bash" >}}
22-
{{< tab header="Linux AMD64" lang="bash">}}
21+
{/* {{< tabpane lang="bash" >}} */} {/* mdx-disabled */}
22+
{/* {{< tab header="Linux AMD64" lang="bash">}} */} {/* mdx-disabled */}
2323
curl -Lo copilotlocal https://github.com/localstack/copilot-cli/raw/localstack-builds/build/linux-amd64/copilotlocal && chmod +x copilotlocal
2424
# if you want to have copilotlocal in your $PATH, move the executable e.g. to /usr/local/bin/
2525

2626
sudo mv copilotlocal /usr/local/bin/
27-
{{< /tab >}}
28-
{{< tab header="Linux ARM64" lang="bash">}}
27+
{/* {/* {/* {/* {{< /tab >}} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */}
28+
{/* {{< tab header="Linux ARM64" lang="bash">}} */} {/* mdx-disabled */}
2929
curl -Lo copilotlocal https://github.com/localstack/copilot-cli/raw/localstack-builds/build/linux-arm64/copilotlocal && chmod +x copilotlocal
3030
# if you want to have copilotlocal in your $PATH, move the executable e.g. to /usr/local/bin/
3131

3232
sudo mv copilotlocal /usr/local/bin/
3333
{{< /tab >}}
34-
{{< tab header="Mac OS" lang="bash">}}
34+
{/* {{< tab header="Mac OS" lang="bash">}} */} {/* mdx-disabled */}
3535
curl -Lo copilotlocal https://github.com/localstack/copilot-cli/raw/localstack-builds/build/macos-darwin/copilotlocal && chmod +x copilotlocal
3636
# if you want to have copilotlocal in your $PATH, move the executable e.g. to /usr/local/bin/
3737

3838
sudo mv copilotlocal /usr/local/bin/
3939
{{< /tab >}}
40-
{{< tab header="Windows Powershell" lang="powershell">}}
40+
{/* {{< tab header="Windows Powershell" lang="powershell">}} */} {/* mdx-disabled */}
4141
Invoke-WebRequest -Uri https://github.com/localstack/copilot-cli/raw/localstack-builds/build/windows/copilotlocal.exe -OutFile copilotlocal.exe
4242
{{< /tab >}}
43-
{{< /tabpane >}}
43+
{/* {{< /tabpane >}} */} {/* mdx-disabled */}
4444

4545
### Configuration
4646

src/content/docs/aws/integrations/aws-sdks/cpp.mdx

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -17,13 +17,13 @@ Consider the following example, which creates an SQS queue, sends a message to i
1717

1818
```cpp
1919
#include <iostream>
20-
#include <aws/core/Aws.h>
21-
#include <aws/core/utils/logging/LogLevel.h>
22-
#include <aws/sqs/SQSClient.h>
23-
#include <aws/sqs/model/CreateQueueRequest.h>
24-
#include <aws/sqs/model/SendMessageRequest.h>
25-
#include <aws/sqs/model/ReceiveMessageRequest.h>
26-
#include <aws/sqs/model/DeleteMessageRequest.h>
20+
{/* #include <aws/core/Aws.h> */} {/* mdx-disabled */}
21+
{/* #include <aws/core/utils/logging/LogLevel.h> */} {/* mdx-disabled */}
22+
{/* #include <aws/sqs/SQSClient.h> */} {/* mdx-disabled */}
23+
{/* #include <aws/sqs/model/CreateQueueRequest.h> */} {/* mdx-disabled */}
24+
{/* #include <aws/sqs/model/SendMessageRequest.h> */} {/* mdx-disabled */}
25+
{/* #include <aws/sqs/model/ReceiveMessageRequest.h> */} {/* mdx-disabled */}
26+
{/* #include <aws/sqs/model/DeleteMessageRequest.h> */} {/* mdx-disabled */}
2727

2828
using namespace Aws;
2929

src/content/docs/aws/integrations/aws-sdks/go.mdx

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@ The Go SDK has two major versions, each with their own way of specifying the Loc
2121
Here is an example of how to create an S3 Client from a Session with the endpoint set to LocalStack.
2222
Full examples for both SDK versions can be found [in our samples repository](https://github.com/localstack/localstack-aws-sdk-examples/tree/main/go).
2323

24-
{{< tabpane lang="golang" >}}
25-
{{< tab header="aws-go-sdk" lang="golang" >}}
24+
{/* {{< tabpane lang="golang" >}} */} {/* mdx-disabled */}
25+
{/* {{< tab header="aws-go-sdk" lang="golang" >}} */} {/* mdx-disabled */}
2626
package main
2727

2828
import (
@@ -45,9 +45,9 @@ func main() {
4545
client := s3.New(sess)
4646

4747
// ...
48-
}{{< /tab >}}
48+
{/* {/* }{{< /tab >}} */} {/* mdx-disabled */} */} {/* mdx-disabled */}
4949

50-
{{< tab header="aws-go-sdk-v2" lang="golang" >}}
50+
{/* {{< tab header="aws-go-sdk-v2" lang="golang" >}} */} {/* mdx-disabled */}
5151
package main
5252

5353
import (
@@ -77,7 +77,7 @@ func main() {
7777
})
7878
// ...
7979
}{{< /tab >}}
80-
{{< /tabpane >}}
80+
{/* {{< /tabpane >}} */} {/* mdx-disabled */}
8181

8282
## Resources
8383

src/content/docs/aws/integrations/aws-sdks/java.mdx

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,8 @@ The client can be used to upload a file to an existing bucket and then retrieve
3838

3939
#### Configuring the S3 Client
4040

41-
{{< tabpane lang="java" >}}
42-
{{< tab header="v1" lang="java" >}}
41+
{/* {/* {/* {/* {{< tabpane lang="java" >}} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */}
42+
{/* {/* {{< tab header="v1" lang="java" >}} */} {/* mdx-disabled */} */} {/* mdx-disabled */}
4343

4444
// Credentials that can be replaced with real AWS values. (To be handled properly and not hardcoded.)
4545
// These can be skipped altogether for LocalStack, but we generally want to avoid discrepancies with production code.
@@ -53,9 +53,9 @@ AmazonS3 s3Client = AmazonS3ClientBuilder.standard()
5353
Regions.US_EAST_1.getName()))
5454
.build();
5555

56-
{{< /tab >}}
56+
{/* {/* {/* {/* {/* {/* {/* {/* {{< /tab >}} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */}
5757

58-
{{< tab header="v2" lang="java" >}}
58+
{/* {/* {{< tab header="v2" lang="java" >}} */} {/* mdx-disabled */} */} {/* mdx-disabled */}
5959

6060
// Credentials that can be replaced with real AWS values. (To be handled properly and not hardcoded.)
6161
// These can be skipped altogether for LocalStack, but we generally want to avoid discrepancies with production code.
@@ -74,7 +74,7 @@ S3Client s3Client = S3Client.builder()
7474
.build();
7575

7676
{{< /tab >}}
77-
{{< /tabpane >}}
77+
{/* {/* {/* {/* {{< /tabpane >}} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */} */} {/* mdx-disabled */}
7878

7979
#### Interacting with S3
8080

@@ -159,7 +159,7 @@ The full list of supported converters can be found
159159
#### Configuring the DynamoDB Client
160160

161161
{{< tabpane lang="java" >}}
162-
{{< tab header="v1" lang="java">}}
162+
{/* {/* {{< tab header="v1" lang="java">}} */} {/* mdx-disabled */} */} {/* mdx-disabled */}
163163

164164
// Credentials that can be replaced with real AWS values. (To be handled properly and not hardcoded.)
165165
// These can be skipped altogether for LocalStack, but we generally want to avoid discrepancies with production code.
@@ -178,7 +178,7 @@ private static AmazonDynamoDB dynamoDBClient = AmazonDynamoDBClientBuilder.stand
178178

179179
{{< /tab >}}
180180

181-
{{< tab header="v2" lang="java">}}
181+
{/* {/* {{< tab header="v2" lang="java">}} */} {/* mdx-disabled */} */} {/* mdx-disabled */}
182182

183183
// Credentials that can be replaced with real AWS values. (To be handled properly and not hardcoded.)
184184
// These can be skipped altogether for LocalStack, but we generally want to avoid discrepancies with production code.

0 commit comments

Comments
 (0)