blob: 64914e9c6a782c096be466329d3f136ce45fbeb9 [file] [log] [blame]
// building-and-running-a-custom-registry-image
[id="building-a-custom-plug-in-registry_{context}"]
= Building a custom plug-in registry
This section describes how to build a custom plug-in registry. Following operations are covered:
* Getting a copy of the source code necessary to build a custom plug-in registry.
* Adding a new plug-in.
* Building the custom plug-in registry.
.Procedure
. Clone the plug-in registry repository:
+
----
include::examples/{project-context}-clone-the-plug-in-registry-repository.adoc[]
----
. In the `./che-plugin-registry/v3/plugins/` directory, create new directories `__<publisher>__/__<plugin-name>__/__<plugin-version>__/` and a `meta.yaml` file in the last directory.
+
.File organization for a plugin
[subs="+quotes"]
----
./che-plugin-registry/v3/plugins/
├── _<publisher>_
│   └── _<plugin-name>_
│   ├── _<plugin-version>_
│   │   └── meta.yaml
│   └── latest.txt
----
. Add valid content to the `meta.yaml` file. See the Using a Visual Studio Code extension in {prod-short}” section or the README.md file in the `eclipse/che-plugin-registry` repository for a detailed description of the `meta.yaml` file format.
. Create a file named `latest.txt` with content the name of the latest `_<plugin-version>_` directory.
+
[TIP]
.Example
====
----
$ tree che-plugin-registry/v3/plugins/redhat/java/
che-plugin-registry/v3/plugins/redhat/java/
├── 0.38.0
│   └── meta.yaml
├── 0.43.0
│   └── meta.yaml
├── 0.45.0
│   └── meta.yaml
├── 0.46.0
│   └── meta.yaml
├── 0.50.0
│   └── meta.yaml
└── latest.txt
$ cat che-plugin-registry/v3/plugins/redhat/java/latest.txt
0.50.0
----
====
. Build the containers for the custom plug-in registry:
+
----
include::examples/{project-context}-build-the-devfile-registry.adoc[]
----