이 콘텐츠는 선택한 언어로 제공되지 않습니다.

Chapter 4. Managing IDE extensions


IDEs use extensions or plugins to extend their functionality, and the mechanism for managing extensions differs between IDEs.

4.1. Extensions for Microsoft Visual Studio Code - Open Source

To manage extensions, this IDE uses one of these Open VSX registry instances:

  • The public, primary open-vsx.org registry.
  • The embedded instance of the Open VSX registry that runs in the plugin-registry pod of OpenShift Dev Spaces to support air-gapped, offline, and proxy-restricted environments. The embedded Open VSX registry contains only a subset of the extensions published on open-vsx.org. This subset can be customized.
  • A standalone Open VSX registry instance, deployed on a network accessible from OpenShift Dev Spaces workspace pods.

4.1.1. Selecting an Open VSX registry instance

The Open VSX registry at https://open-vsx.org is the default if resolved from within your organization’s cluster. If not, then the embedded Open VSX registry within the OpenShift Dev Spaces plugin-registry pod is the default.

If the default Open VSX registry instance is not what you need, you can select another Open VSX registry instance as follows.

Procedure

  • Edit the openVSXURL value in the CheCluster custom resource:

    spec:
      components:
        pluginRegistry:
          openVSXURL: "<url_of_an_open_vsx_registry_instance>"
    Tip
    • The default openVSXURL value is https://open-vsx.org.
    • To select the embedded Open VSX registry instance in the plugin-registry pod, use openVSXURL: ''. See the next section for how to customize the included extensions.
    • You can also point openVSXURL at the URL of a standalone Open VSX registry instance if its URL is accessible from within your organization’s cluster and not blocked by a proxy.

4.1.2. Adding or removing extensions in the embedded Open VSX registry instance

You can add or remove extensions in the embedded Open VSX registry instance deployed by OpenShift Dev Spaces to support offline and proxied environments.

This will create a custom build of the Open VSX registry, which can be used in your organization’s workspaces.

Tip

To get the latest security fixes after a OpenShift Dev Spaces update, rebuild your container based on the latest tag or SHA.

Procedure

  1. Download or fork and clone the plugin registry repository.
  2. For each extension that you need to add or remove, edit the openvsx-sync.json file:

    • If the extension is published on open-vsx.org, you can add its extension id in the format <published_by>.<unique_identifier>. You can find the id details on the extension’s listing page on open-vsx.org.

          {
              "id": "<published_by>.<unique_identifier>"
          }
      Tip

      The latest extension version on open-vsx.org is the default. Alternatively, you can add "version": "<extension_version>" on a new line to specify a version.

    • If the extension is only available from Microsoft Visual Studio Marketplace, but not Open VSX, you can ask the extension publisher to also publish it on open-vsx.org according to these instructions, potentially using this GitHub action.

      Tip
      • If the extension publisher is unavailable or unwilling to publish the extension to open-vsx.org, and if there is no Open VSX equivalent of the extension, consider reporting an issue to the Open VSX team.
      • If you have a closed-source extension or an extension developed only for internal use in your company, you can add the extension directly from a .vsix file by using a URL accessible to your custom plugin registry container:

            {
                "id": "<published_by>.<unique_identifier>",
                "download": "<url_to_download_vsix_file>",
                "version": "<extension_version>"
            }
      Warning

      Please read the Terms of Use for the Microsoft Visual Studio Marketplace before using its resources.

    • You can remove the extension by deleting it from the openvsx-sync.json file.
  3. Build the plugin registry container image and publish it to a container registry like quay.io:

    1. $ ./build.sh -o <username> -r quay.io -t custom
    2. $ podman push quay.io/<username/plugin_registry:custom>
  4. Edit the CheCluster custom resource in your organization’s cluster to point to the image (for example, on quay.io) and then save the changes:

    spec:
      components:
        pluginRegistry:
          deployment:
            containers:
              - image: quay.io/<username/plugin_registry:custom>
          openVSXURL: ''
  5. Check that the plugin-registry pod has restarted and is running.
  6. Restart the workspace and check the available extensions in the Extensions view of the workspace IDE.
Red Hat logoGithubRedditYoutubeTwitter

자세한 정보

평가판, 구매 및 판매

커뮤니티

Red Hat 문서 정보

Red Hat을 사용하는 고객은 신뢰할 수 있는 콘텐츠가 포함된 제품과 서비스를 통해 혁신하고 목표를 달성할 수 있습니다.

보다 포괄적 수용을 위한 오픈 소스 용어 교체

Red Hat은 코드, 문서, 웹 속성에서 문제가 있는 언어를 교체하기 위해 최선을 다하고 있습니다. 자세한 내용은 다음을 참조하세요.Red Hat 블로그.

Red Hat 소개

Red Hat은 기업이 핵심 데이터 센터에서 네트워크 에지에 이르기까지 플랫폼과 환경 전반에서 더 쉽게 작업할 수 있도록 강화된 솔루션을 제공합니다.

© 2024 Red Hat, Inc.