1
0
mirror of https://github.com/openshift/openshift-docs.git synced 2026-02-05 12:46:18 +01:00
Files
openshift-docs/modules/serverless-update-subscriptions-kn.adoc
2021-06-24 11:21:54 -05:00

36 lines
1.4 KiB
Plaintext

[id="serverless-update-subscriptions-kn_{context}"]
= Updating subscriptions by using the Knative CLI
You can update a subscription by using the `kn` CLI.
.Prerequisites
To update subscriptions using the `kn` CLI, ensure that:
* The {ServerlessOperatorName} and Knative Eventing are installed on your {product-title} cluster.
* You have installed the `kn` CLI.
* You have access to a project with the appropriate roles and permissions to create applications and other workloads in {product-title}.
* You have created a subscription.
.Procedure
* Update a subscription:
+
[source,terminal]
----
$ kn subscription update <subscription_name> \
--sink <sink_prefix>:<sink_name> \ <1>
--sink-dead-letter <sink_prefix>:<sink_name> <2>
----
<1> `--sink` specifies the updated target destination to which the event should be delivered. You can specify the type of the sink by using one of the following prefixes:
`ksvc`:: A Knative service.
`channel`:: A channel that should be used as destination. Only default channel types can be referenced here.
`broker`:: An Eventing broker.
<2> Optional: `--sink-dead-letter` is an optional flag that can be used to specify a sink which events should be sent to in cases where events fail to be delivered. For more information, see the {ServerlessProductName} _Event delivery_ documentation.
+
.Example command
[source,terminal]
----
$ kn subscription update mysubscription --sink ksvc:event-display
----