Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: enabled s2i for python #1562

Merged
merged 6 commits into from
Feb 20, 2023
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
17,010 changes: 8,511 additions & 8,499 deletions generate/zz_filesystem_generated.go

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions pkg/builders/s2i/builder.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ var DefaultBuilderImages = map[string]string{
"nodejs": "registry.access.redhat.com/ubi8/nodejs-16",
"typescript": "registry.access.redhat.com/ubi8/nodejs-16",
"quarkus": "registry.access.redhat.com/ubi8/openjdk-17",
"python": "registry.access.redhat.com/ubi8/python-39",
}

// DockerClient is subset of dockerClient.CommonAPIClient required by this package
Expand Down
4 changes: 2 additions & 2 deletions pkg/builders/s2i/builder_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -64,9 +64,9 @@ func Test_BuildImages(t *testing.T) {
wantErr: true,
},
{
name: "Without builder - unsupported runtime - python",
name: "Without builder - supported runtime - python",
function: fn.Function{Runtime: "python"},
wantErr: true,
wantErr: false,
},
{
name: "Without builder - unsupported runtime - rust",
Expand Down
3 changes: 3 additions & 0 deletions templates/python/cloudevents/app.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/bin/sh

exec python -m parliament "$(dirname "$0")"
3 changes: 3 additions & 0 deletions templates/python/http/app.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/bin/sh

exec python -m parliament "$(dirname "$0")"
2 changes: 1 addition & 1 deletion test/oncluster/scenario_runtime_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import (
var runtimeSupportMap = map[string][]string{
"node": {"pack", "s2i"},
"go": {},
"python": {"pack"},
"python": {"pack", "s2i"},
"quarkus": {"pack", "s2i"},
"springboot": {"pack"},
"typescript": {"pack", "s2i"},
Expand Down