mirror of
https://github.com/openshift/openshift-docs.git
synced 2026-02-06 06:46:26 +01:00
36 lines
908 B
Plaintext
36 lines
908 B
Plaintext
// Module included in the following assemblies:
|
|
//
|
|
// * serverless/event_workflows/serverless-channels.adoc
|
|
|
|
[id="serverless-create-inmemorychannel-yaml_{context}"]
|
|
= Creating a channel using YAML
|
|
|
|
You can create a channel by using YAML with the cluster default configuration.
|
|
|
|
.Prerequisites
|
|
To create channels ensure that:
|
|
|
|
* The {ServerlessOperatorName} and Knative Eventing are installed on your {product-title} cluster.
|
|
* You have created a project or have access to a project with the appropriate roles and permissions to create applications and other workloads in {product-title}.
|
|
|
|
.Procedure
|
|
|
|
To create a `Channel` object:
|
|
|
|
. Create a YAML file and copy the following sample code into it:
|
|
+
|
|
[source,yaml]
|
|
----
|
|
apiVersion: messaging.knative.dev/v1
|
|
kind: Channel
|
|
metadata:
|
|
name: example-channel
|
|
namespace: default
|
|
----
|
|
. Apply the YAML file:
|
|
+
|
|
[source,terminal]
|
|
----
|
|
$ oc apply -f <filename>
|
|
----
|