VS Code extension for Hydrate, which crawls a kubernetes cluster and generates a high level description of your deployments.
Перейти к файлу
Madeline Liao c107a47aef
1.3.1 (#43)
2019-08-22 10:37:06 -07:00
.vscode initial hello world sample extension 2019-07-09 16:36:16 -07:00
src Added docker pull command (#41) 2019-08-21 16:31:37 -07:00
.gitignore Added Azure pipeline yaml and sample tests (#20) 2019-07-19 10:23:34 -07:00
.vscodeignore initial hello world sample extension 2019-07-09 16:36:16 -07:00
CHANGELOG.md initial hello world sample extension 2019-07-09 16:36:16 -07:00
LICENSE Initial commit 2019-07-01 11:39:09 -07:00
README.md Run Hydrate on Docker (#38) 2019-08-20 10:27:26 -07:00
azure-pipelines.yml Added Azure pipeline yaml and sample tests (#20) 2019-07-19 10:23:34 -07:00
package-lock.json 1.3.1 (#43) 2019-08-22 10:37:06 -07:00
package.json 1.3.1 (#43) 2019-08-22 10:37:06 -07:00
tsconfig.json initial hello world sample extension 2019-07-09 16:36:16 -07:00
tslint.json initial hello world sample extension 2019-07-09 16:36:16 -07:00
vsc-extension-quickstart.md Added Hydrate dropdown to sidebar (#15) 2019-07-15 14:29:24 -07:00

README.md

Hydrate Extension for Visual Studio Code

Build Status

Overview

This is the Visual Studio Code Hydrate extension, which builds upon the VSCode Kubernetes Extension. It allows developers to use Hydrate within VSCode, which crawls a Kubernetes cluster and generates a high level description in a component.yaml file for its deployments.

Instead of running Hydrate from the command line and entering flags and options manually, this extension allows users to select a Kubernetes cluster and run Hydrate within VSCode.

Install the Extension!

First, make sure that you have Docker set up (the extension runs Hydrate on Docker). Next, download the extension here. If you do not have the VSCode Kubernetes Extension installed, it will automatically be installed during the Hydrate extension installation. A window reload is required after installation.

Navigate to the Kubernetes view by clicking the Kubernetes icon in the sidebar. Right-click the cluster you would like to run Hydrate on, and select Hydrate Cluster. You will be prompted step-by-step through selecting options for Hydrate (e.g. output file path).

Note: all clusters displayed in the sidebar are associated with the same kubeconfig file. To test out a different kubeconfig, click the "options" icon (the three dots) in the Kubernetes extension cluster explorer and click Set Kubeconfig to change the current kubeconfig file used. Then, you can run Hydrate on the newly displayed clusters with the new kubeconfig.

For example, the results of running a verbose dry-run:

alt text

Testing the Extension

First, clone the repo locally by running the following command:

git clone https://github.com/microsoft/vscode-hydrate

There are two ways to run tests:

  1. From the command line, within the vscode-hydrate directory, run:
npm test
  1. Alternatively, tests can be run in VSCode. From wherever the cloned repo lives, run:
code ./vscode-hydrate

Then, navigate to the Debugger view in the sidebar. Click the dropdown next to the green 'play' button, and click Extension Tests. Then click the play button to run the tests. Output will be printed to the VSCode Debug Console.

Dependencies

Contributing

This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.microsoft.com.

When you submit a pull request, a CLA-bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., label, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repos using our CLA.

This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional questions or comments.