Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion samcli/commands/build/command.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@
------------------
1. Python 3.8, 3.9, 3.10, 3.11, 3.12, 3.13 using PIP\n
2. Nodejs 22.x, Nodejs 20.x, 18.x, 16.x, 14.x, 12.x using NPM\n
3. Ruby 3.2, 3.3 using Bundler\n
3. Ruby 3.2, 3.3, 3.4 using Bundler\n
4. Java 8, Java 11, Java 17, Java 21 using Gradle and Maven\n
5. Dotnet8, Dotnet6 using Dotnet CLI\n
6. Go 1.x using Go Modules (without --use-container)\n
Expand Down
2 changes: 2 additions & 0 deletions samcli/lib/build/workflow_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,7 @@ def get_layer_subfolder(build_workflow: str) -> str:
"nodejs22.x": "nodejs",
"ruby3.2": "ruby/lib",
"ruby3.3": "ruby/lib",
"ruby3.4": "ruby/lib",
"java11": "java",
"java8.al2": "java",
"java17": "java",
Expand Down Expand Up @@ -167,6 +168,7 @@ def get_workflow_config(
"nodejs22.x": BasicWorkflowSelector(NODEJS_NPM_CONFIG),
"ruby3.2": BasicWorkflowSelector(RUBY_BUNDLER_CONFIG),
"ruby3.3": BasicWorkflowSelector(RUBY_BUNDLER_CONFIG),
"ruby3.4": BasicWorkflowSelector(RUBY_BUNDLER_CONFIG),
"dotnet6": BasicWorkflowSelector(DOTNET_CLIPACKAGE_CONFIG),
"dotnet8": BasicWorkflowSelector(DOTNET_CLIPACKAGE_CONFIG),
"go1.x": BasicWorkflowSelector(GO_MOD_CONFIG),
Expand Down
1 change: 1 addition & 0 deletions samcli/lib/utils/architecture.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
"python3.13": [ARM64, X86_64],
"ruby3.2": [ARM64, X86_64],
"ruby3.3": [ARM64, X86_64],
"ruby3.4": [ARM64, X86_64],
"java8.al2": [ARM64, X86_64],
"java11": [ARM64, X86_64],
"java17": [ARM64, X86_64],
Expand Down
4 changes: 3 additions & 1 deletion samcli/local/common/runtime_template.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
],
"ruby": [
{
"runtimes": ["ruby3.3", "ruby3.2"],
"runtimes": ["ruby3.4", "ruby3.3", "ruby3.2"],
"dependency_manager": "bundler",
"init_location": os.path.join(_templates, "cookiecutter-aws-sam-hello-ruby"),
"build": True,
Expand Down Expand Up @@ -125,6 +125,7 @@ def get_local_lambda_images_location(mapping, runtime):
"python3.9",
"python3.8",
# ruby runtimes in descending order
"ruby3.4",
"ruby3.3",
"ruby3.2",
]
Expand All @@ -150,6 +151,7 @@ def get_local_lambda_images_location(mapping, runtime):
"python3.10": "amazon/python3.10-base",
"python3.9": "amazon/python3.9-base",
"python3.8": "amazon/python3.8-base",
"ruby3.4": "amazon/ruby3.4-base",
"ruby3.3": "amazon/ruby3.3-base",
"ruby3.2": "amazon/ruby3.2-base",
}
Expand Down
1 change: 1 addition & 0 deletions samcli/local/docker/lambda_image.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ class Runtime(Enum):
python313 = "python3.13"
ruby32 = "ruby3.2"
ruby33 = "ruby3.3"
ruby34 = "ruby3.4"
java8al2 = "java8.al2"
java11 = "java11"
java17 = "java17"
Expand Down
19 changes: 11 additions & 8 deletions schema/samcli.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion tests/integration/buildcmd/test_build_cmd.py
Original file line number Diff line number Diff line change
Expand Up @@ -316,7 +316,7 @@ def _prepare_application_environment(self, runtime):
└── template.yaml
"""
# copy .ruby-version to the root of the project
ruby_runtime_path = "Ruby32" if runtime == "ruby3.2" else "Ruby33"
ruby_runtime_path = runtime.replace(".", "").title() # ruby3.X to Ruby3X
shutil.copyfile(
Path(self.template_path).parent.joinpath(ruby_runtime_path, ".ruby-version"),
Path(self.working_dir).joinpath(".ruby-version"),
Expand Down
2 changes: 1 addition & 1 deletion tests/unit/lib/build_module/test_workflow_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ def test_raise_exception_for_bad_specified_workflow(self, runtime):
with self.assertRaises(UnsupportedBuilderException):
get_workflow_config(runtime, self.code_dir, self.project_dir, specified_workflow="Wrong")

@parameterized.expand([("ruby3.2",)])
@parameterized.expand([("ruby3.2",), ("ruby3.3",), ("ruby3.4",)])
def test_must_work_for_ruby(self, runtime):
result = get_workflow_config(runtime, self.code_dir, self.project_dir)
self.assertEqual(result.language, "ruby")
Expand Down
Loading