Skip to content

Commit b694ecd

Browse files
author
Jan Kammerath
committed
changed build to put the binary into the bin folder to simplify deployment
1 parent 499ece9 commit b694ecd

File tree

4 files changed

+17
-3
lines changed

4 files changed

+17
-3
lines changed

.gitignore

+3-1
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,6 @@
22
bootstrap
33
*.resolved
44
.swiftpm
5-
.vscode
5+
.vscode
6+
*.toml
7+
bin

.samignore

+12
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
.build
2+
.swiftpm
3+
.vscode
4+
src
5+
.gitignore
6+
Makefile
7+
*.resolved
8+
*.swift
9+
*.md
10+
*.sh
11+
*.toml
12+
*.yaml

Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@ clean:
55

66
build:
77
docker run --rm --platform linux/arm64 -v "$(PWD):/src" -w /src swift:5.9.1-amazonlinux2 /bin/bash \
8-
-c "swift build --product ServerlessSwift -c release --static-swift-stdlib -Xswiftc -static-stdlib; mv .build/release/ServerlessSwift bootstrap"
8+
-c "swift build --product ServerlessSwift -c release --static-swift-stdlib -Xswiftc -static-stdlib; mkdir -p bin; mv .build/release/ServerlessSwift bin/bootstrap"

template.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ Resources:
1313
Properties:
1414
Handler: bootstrap
1515
Runtime: provided.al2
16-
CodeUri: .
16+
CodeUri: ./bin/
1717
MemorySize: 128
1818
Timeout: 30
1919
Architectures:

0 commit comments

Comments
 (0)