1
0
mirror of https://github.com/openshift/openshift-docs.git synced 2026-02-05 12:46:18 +01:00
Files
openshift-docs/modules/cli-manager-adding-plugin-yaml.adoc
2025-10-06 16:34:01 -04:00

74 lines
1.8 KiB
Plaintext

// Module included in the following assemblies:
//
// * cli_reference/cli_manager/cli-manager-install.adoc
:_mod-docs-content-type: PROCEDURE
[id="cli-manager-adding-plugin-yamls_{context}"]
= Adding a plugin to the {cli-manager}
You can add a CLI plugin to the {cli-manager} by using the YAML View.
.Prerequisites
* You are logged in to {product-title} as a user with the `cluster-admin` role.
* The {cli-manager} is installed.
.Procedure
. Log in to the {product-title} web console.
. Navigate to *Ecosystem* -> *Installed Operators*.
. From the list, select *{cli-manager}*.
. Select the *CLI Plugin* tab.
. Click *Create Plugin*.
. In the text box, enter the information for the plugin you are installing. See the following example YAML file.
+
.Example YAML file to add a plugin
[source,yaml]
----
apiVersion: config.openshift.io/v1alpha1
kind: Plugin
metadata:
name: <plugin_name> <1>
spec:
description: <description_of_plugin>
homepage: <plugin_homepage>
platforms:
- bin: <2>
files:
- from: <plugin_file_path>
to: .
image: <plugin_image>
imagePullSecret: <3>
platform: <platform> <4>
shortDescription: <short_description_of_plugin>
version: <version> <5>
----
<1> The name of the plugin you plan to use in commands.
<2> `Bin` specifies the path to the plugin executable.
<3> Optional: If the registry is not public, add a pull secret to access your plugin image.
<4> Add the architecture for your system; for example, `linux/amd64`, `darwin/arm64`, `windows/amd64`, or another architecture.
<5> Version must be in v0.0.0 format.
. Click *Save*.
.Verification
* Enter the following command to see if the plugin is listed and has been added successfully:
[source,terminal]
----
$ oc get plugin/<plugin_name> -o yaml
----
.Example output
[source,terminal]
----
<plugin_name> ready to be served.
----