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
{{ message }}
This repository was archived by the owner on Mar 19, 2024. It is now read-only.
- Clone the repo `git clone https://github.com/swift-sprinter/aws-lambda-swift-sprinter.git`
367
+
368
+
### Build:
369
+
- From command line run `make docker_build`
370
+
- From command line run `make package_layer`
371
+
- From command line run `make package_lambda`
372
+
373
+
### Configure:
374
+
- Go to `AWS Lambda -> Layers` in AWS Console and create a new layer from scratch
375
+
- Enter layer name "swift-lambda-runtime-5-1-1"
376
+
- Upload the zip file `build/swift-lambda-runtime-5-1-1.zip`
377
+
- Leave "Compatible runtimes" empty.
378
+
- Click "Create"
379
+
- Copy the `arn` from the created layer, it's required to set up the lambda.
380
+
- Go to `AWS Lambda` in AWS Console and create a new function from scratch
381
+
- Enter function name "benchmark-swift-hello" and select "Provide your own bootstrap" as runtime
382
+
- Choose the execution role created above
383
+
- Upload the zip file created with function code, it can be found under `build/lambda.zip`
384
+
- Input "HelloWorld.helloWorld" in "Handler" (`Executable.Handler`)
385
+
- Click "Layers"
386
+
- Click "Add Layer"
387
+
- Click "Provide a layer version"
388
+
- Add the `arn` of the layer you have uploaded previously.
389
+
- Click "Add"
390
+
- Click "Save"
391
+
392
+
### Test:
393
+
- Test the function by clicking `Test` in the top right corner and add the following event:
394
+
```
395
+
{
396
+
"name": "Swift-Sprinter"
397
+
}
398
+
```
399
+
- Give a name to the event, save and then test it.
400
+
361
401
# Contributions
362
402
363
403
Contributions are more than welcome! Follow [this guide](https://github.com/swift-sprinter/aws-lambda-swift-sprinter/blob/master/CONTRIBUTING.md) to contribute.
0 commit comments