Skip to content

Commit 28d7c87

Browse files
committed
Add build instructions to README
1 parent 386f50a commit 28d7c87

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

swift/example_code/lambda/README.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,21 @@ This example shows you how to do the following:
8585

8686

8787
<!--custom.basics.lambda_Scenario_GettingStartedFunctions.start-->
88+
##### Build and deploy the example
89+
90+
This example consists of the main program and two AWS Lambda functions. To
91+
build and deploy it:
92+
93+
1. Build the `increment` lambda function (`cd increment && swift build`).
94+
2. Archive the `increment` lambda function for use as a Lambda function:
95+
`swift package archive --allow-network-connections docker`. When archiving
96+
is complete, the archive's path is displayed. Take note of it.
97+
3. Build the `calculator` lambda function (`cd ../calculator && swift build`).
98+
4. Archive it for use as a Lambda function: `swift package archive
99+
--allow-network-connections docker`. Take note of this created Zip file's
100+
path, too.
101+
5. Build the main program in the `lambda-basics` directory.
102+
6. Run the main program with the command `swift run lambda-basics --incpath <path-of-increment-archive> --calcpath <path-of-calculator-archive>`.
88103
<!--custom.basics.lambda_Scenario_GettingStartedFunctions.end-->
89104

90105

0 commit comments

Comments
 (0)