|
15 | 15 | #set($resourceName = "#replaceChar($resourceName, '-')") |
16 | 16 | #set($resourceName = "#replaceChar($resourceName, '.')") |
17 | 17 | #set($resourceName = $resourceName.replaceAll("\n", "").trim()) |
18 | | -# ${artifactId} serverless API |
19 | | -The ${artifactId} project, created with [`aws-serverless-java-container`](https://github.com/awslabs/aws-serverless-java-container). |
| 18 | +# \${artifactId} serverless API |
| 19 | +The \${artifactId} project, created with [`aws-serverless-java-container`](https://github.com/awslabs/aws-serverless-java-container). |
20 | 20 |
|
21 | 21 | The starter project defines a simple `/ping` resource that can accept `GET` requests with its tests. |
22 | 22 |
|
23 | | -The project folder also includes a `sam.yaml` file. You can use this [SAM](https://github.com/awslabs/serverless-application-model) file to deploy the project to AWS Lambda and Amazon API Gateway or test in local with [SAM Local](https://github.com/awslabs/aws-sam-local). |
| 23 | +The project folder also includes a `sam.yaml` file. You can use this [SAM](https://github.com/awslabs/serverless-application-model) file to deploy the project to AWS Lambda and Amazon API Gateway or test in local with [SAM Local](https://github.com/awslabs/aws-sam-local). |
24 | 24 |
|
25 | 25 | ## Building the project |
26 | | -Using [Maven](https://maven.apache.org/), you can create an AWS Lambda-compatible jar file simply by running the maven package command from the projct folder. |
27 | | - |
| 26 | +Using [Maven](https://maven.apache.org/), you can create an AWS Lambda-compatible zip file simply by running the maven package command from the projct folder. |
28 | 27 | ```bash |
29 | | -$ mvn archetype:generate -DartifactId=my-spring-api -DarchetypeGroupId=com.amazonaws.serverless.archetypes -DarchetypeArtifactId=aws-serverless-spring-archetype -DarchetypeVersion=1.0-SNAPSHOT -DgroupId=com.sapessi.spring -Dversion=0.1 -Dinteractive=false |
30 | | -$ cd my-spring-api |
| 28 | +$ mvn archetype:generate -DartifactId=\${artifactId} -DarchetypeGroupId=com.amazonaws.serverless.archetypes -DarchetypeArtifactId=aws-serverless-springboot2-archetype -DarchetypeVersion=${project.version} -DgroupId=\${groupId} -Dversion=\${version} -Dinteractive=false |
| 29 | +$ cd \${artifactId} |
31 | 30 | $ mvn clean package |
32 | 31 |
|
33 | 32 | [INFO] ------------------------------------------------------------------------ |
@@ -100,8 +99,8 @@ $ aws cloudformation describe-stacks --stack-name ServerlessSpringApi |
100 | 99 | "Outputs": [ |
101 | 100 | { |
102 | 101 | "Description": "URL for application", |
103 | | - "ExportName": "${resourceName}Api", |
104 | | - "OutputKey": "${resourceName}Api", |
| 102 | + "ExportName": "\${resourceName}Api", |
| 103 | + "OutputKey": "\${resourceName}Api", |
105 | 104 | "OutputValue": "https://xxxxxxx.execute-api.us-west-2.amazonaws.com/Prod/ping" |
106 | 105 | } |
107 | 106 | ], |
|
0 commit comments