Skip to content

Commit db3f7e4

Browse files
authored
Merge pull request #48899 from rh-max/srvls-kn-func-buildpack-s2i
[SRVOCF-418, SRVOCF-422] Update `kn func build` docs regarding Buildpacks and S2I
2 parents 99b267c + 6188fc4 commit db3f7e4

File tree

3 files changed

+16
-11
lines changed

3 files changed

+16
-11
lines changed

modules/serverless-build-func-kn.adoc

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,21 @@
88

99
Before you can run a function, you must build the function project by using the `kn func build` command. This command creates an OCI container image that can be run locally on your computer or on an {product-title} cluster. The build command uses the function project name and the image registry name to construct a fully qualified image name for your function.
1010

11+
By default, `kn func build` creates a container image using the Red Hat Source-to-Image (S2I) technology. To use the link:https://buildpacks.io/[CNCF Cloud Native Buildpacks] technology instead, supply the `-b` flag:
12+
13+
.Example build command
14+
[source,terminal]
15+
----
16+
$ kn func build -b pack
17+
----
18+
19+
.Example output
20+
[source,terminal]
21+
----
22+
Building function image
23+
Function image has been built, image: registry.redhat.io/example/example-function:latest
24+
----
25+
1126
The OpenShift Container Registry is used by default as the image registry for storing function images. You can override this by using the `-r` flag:
1227

1328
.Example build command

modules/serverless-functions-func-yaml-fields.adoc

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -8,16 +8,6 @@
88

99
Many of the fields in `func.yaml` are generated automatically when you create, build, and deploy your function. However, there are also fields that you modify manually to change things, such as the function name or the image name.
1010

11-
[id="serverless-functions-func-yaml-builder_{context}"]
12-
== builder
13-
14-
The `builder` field specifies the Buildpack builder image to use when building the function. In most cases, this value should not be changed. When you do change it, use a value that is listed in the `builders` field.
15-
16-
[id="serverless-functions-func-yaml-builders_{context}"]
17-
== builders
18-
19-
Some function runtimes can be built in multiple ways. For example, a Quarkus function can be built for the JVM or as a native binary. The `builders` field contains all of the builders available for a given runtime.
20-
2111
[id="serverless-functions-func-yaml-buildenvs_{context}"]
2212
== buildEnvs
2313

serverless/discover/serverless-functions-about.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ include::_attributes/common-attributes.adoc[]
66

77
toc::[]
88

9-
With {FunctionsProductName}, developers can create and deploy stateless, event-driven functions as a Knative service on {product-title}. The Knative (`kn`) CLI is provided as a plug-in for the Knative CLI. {FunctionsProductName} uses the link:https://buildpacks.io/[CNCF Buildpack API] to create container images. After a container image is created, you can use the `kn func` CLI to deploy the container image as a Knative service on the cluster.
9+
{FunctionsProductName} enables developers to create and deploy stateless, event-driven functions as a Knative service on {product-title}. The `kn func` CLI is provided as a plug-in for the Knative `kn` CLI. You can use the `kn func` CLI to create, build, and deploy the container image as a Knative service on the cluster.
1010

1111
:FeatureName: {FunctionsProductName}
1212
include::snippets/technology-preview.adoc[leveloffset=+2]

0 commit comments

Comments
 (0)