Skip to content

Commit cb482f6

Browse files
committed
Java 21 Cleanup
1 parent a71040c commit cb482f6

File tree

2 files changed

+18
-5
lines changed

2 files changed

+18
-5
lines changed

.github/workflows/build.yml

+17-4
Original file line numberDiff line numberDiff line change
@@ -17,15 +17,28 @@ jobs:
1717
- name: Checkout Code
1818
uses: actions/checkout@v4
1919

20+
- name: Set up JDK 21
21+
uses: actions/setup-java@v4
22+
with:
23+
java-version: '21'
24+
distribution: 'corretto'
25+
cache: maven
26+
2027
- name: Setup AWS SAM
2128
uses: aws-actions/setup-sam@v2
2229
with:
2330
use-installer: true
2431

25-
# Having SAM build inside container then removes all Maven/Java requirements
26-
# The image SAM pulls will build the lambda correctly
27-
- name: Build inside Docker containers
28-
run: sam build --use-container
32+
- name: Setup AWS SAM
33+
uses: aws-actions/setup-sam@v2
34+
with:
35+
use-installer: true
36+
37+
- name: SAM Build
38+
run: sam build
39+
40+
- name: Validate SAM Template
41+
run: sam validate --lint
2942

3043

3144

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ To use the SAM CLI, you need the following tools.
4848
If you have brew installed then
4949
```bash
5050
brew install aws-sam-cli
51-
brew install corretto21
51+
brew install corretto@21
5252
brew install maven
5353
```
5454

0 commit comments

Comments
 (0)