Skip to content

Commit

Permalink
set workflows, docs back to 0.26.0
Browse files Browse the repository at this point in the history
Signed-off-by: Kingdon P Barrett <[email protected]>
  • Loading branch information
kingdonb committed Jan 20, 2024
1 parent 5db24d9 commit 404fe19
Show file tree
Hide file tree
Showing 6 changed files with 58 additions and 29 deletions.
22 changes: 11 additions & 11 deletions .github/workflows/build-vsix.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,17 +64,17 @@ jobs:
fi;
- name: Clone Repository
uses: actions/checkout@dc323e67f16fb5f7663d20ff7941f27f5809e9b6 # pin@v2
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # pin@v3
with:
fetch-depth: 0

- name: Setup Flux CLI
uses: fluxcd/flux2/action@2c7d650d4472bb7c92fa5fea86589527dfa5abcc # pin@main
uses: fluxcd/flux2/action@1730f3c46bddf0a29787d8d4fa5ace283f298e49 # pin@main
with:
token: ${{ secrets.GITHUB_TOKEN }}

- name: Setup Node version
uses: actions/setup-node@f1f314fca9dfce2769ece7d933488f076716723e # pin@v1
uses: actions/setup-node@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d # pin@v3
with:
node-version: 19

Expand All @@ -96,11 +96,11 @@ jobs:
- name: Setup Kubernetes
uses: engineerd/setup-kind@aa272fe2a7309878ffc2a81c56cfe3ef108ae7d0 # [email protected]
with:
version: v0.17.0
image: kindest/node:v1.23.13
version: v0.20.0
image: kindest/node:v1.28.0

- name: Run Tests
uses: GabrielBB/xvfb-action@86d97bde4a65fe9b290c0b3fb92c2c4ed0e5302d # pin@v1
uses: coactions/setup-xvfb@b6b4fcfb9f5a895edadc3bc76318fae0ac17c8b3 # pin@v1
with:
run: npm test
options: "-screen 0 1600x1200x24"
Expand Down Expand Up @@ -167,15 +167,15 @@ jobs:
if: ${{ github.event.inputs.publishMarketplace == 'yes' && github.event.inputs.releaseChannel == 'stable' }}

- name: Publish to Open VSX Registry (Edge)
uses: HaaLeo/publish-vscode-extension@c1a0486c5a3eed24e8c21d4e37889a7c4c60c443 # pin@v1
uses: HaaLeo/publish-vscode-extension@dfe4f6ad46624424fe24cb5bca79839183399045 # pin@v1
if: ${{ github.event.inputs.publishOpenVSX == 'yes' && github.event.inputs.releaseChannel == 'edge' }}
with:
preRelease: true
pat: ${{ secrets.OPEN_VSX_TOKEN }}
extensionFile: ./gitops-tools-${{ env.RELEASE_VERSION }}.vsix

- name: Publish to Open VSX Registry (Stable)
uses: HaaLeo/publish-vscode-extension@c1a0486c5a3eed24e8c21d4e37889a7c4c60c443 # pin@v1
uses: HaaLeo/publish-vscode-extension@dfe4f6ad46624424fe24cb5bca79839183399045 # pin@v1
if: ${{ github.event.inputs.publishOpenVSX == 'yes' && github.event.inputs.releaseChannel == 'stable' }}
with:
preRelease: false
Expand All @@ -199,7 +199,7 @@ jobs:
echo "GIT_TAG=$GIT_TAG" >> $GITHUB_ENV
- name: GitHub Release
uses: ncipollo/release-action@a2e71bdd4e7dab70ca26a852f29600c98b33153e # pin@v1
uses: ncipollo/release-action@6c75be85e571768fa31b40abf38de58ba0397db5 # pin@v1
with:
artifacts: "./gitops-tools-*"
bodyFile: ${{ github.workspace }}-CHANGELOG.txt
Expand Down Expand Up @@ -228,14 +228,14 @@ jobs:
Feature branches should still be squashed, but \`release-pr\` must always be merged to complete the release.
See the [DEVELOPMENT.md](https://github.com/weaveworks/vscode-gitops-tools/blob/main/DEVELOPMENT.md#releasing) for more information about the release process.
See the [CONTRIBUTING.md](https://github.com/weaveworks/vscode-gitops-tools/blob/main/CONTRIBUTING.md#releasing) for more information about the release process.
pr_reviewer: ${{ github.actor }}
pr_draft: false
github_token: ${{ secrets.GITHUB_TOKEN }}

# - name: Get the version
# id: version
# run: echo ::set-output name=VERSION::${GITHUB_REF/refs\/tags\//}
# run: echo "VERSION=${GITHUB_REF/refs\/tags\//}" >> $GITHUB_OUTPUT
# shell: bash
#
# - uses: apexskier/github-semver-parse@671ddf80785e4d721e76723ec1e687317f85bfe9 # pin@v1
Expand Down
14 changes: 7 additions & 7 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,27 +11,27 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@ac593985615ec2ede58e132d2e21d2b1cbd6127c # pin@v3
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # pin@v3

- uses: actions/setup-node@64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c # pin@v3
- uses: actions/setup-node@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d # pin@v3
with:
node-version: '19'
node-version: '20'

- run: npm install

- name: Setup Kubernetes
uses: engineerd/setup-kind@aa272fe2a7309878ffc2a81c56cfe3ef108ae7d0 # [email protected]
with:
version: v0.17.0
image: kindest/node:v1.23.13
version: v0.20.0
image: kindest/node:v1.28.0

- name: Setup Flux CLI
uses: fluxcd/flux2/action@2c7d650d4472bb7c92fa5fea86589527dfa5abcc # pin@main
uses: fluxcd/flux2/action@1730f3c46bddf0a29787d8d4fa5ace283f298e49 # pin@main
with:
token: ${{ secrets.GITHUB_TOKEN }}

- name: extension test
uses: GabrielBB/xvfb-action@86d97bde4a65fe9b290c0b3fb92c2c4ed0e5302d # pin@v1
uses: coactions/setup-xvfb@b6b4fcfb9f5a895edadc3bc76318fae0ac17c8b3 # pin@v1
with:
run: 'npm test'
options: "-screen 0 1600x1200x24"
File renamed without changes.
45 changes: 37 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# GitOps Tools for Visual Studio Code

[![VSCode Marketplace Link](https://vsmarketplacebadges.dev/version-short/weaveworks.vscode-gitops-tools.png)](https://marketplace.visualstudio.com/items?itemName=Weaveworks.vscode-gitops-tools)
[![Install Counter](https://vsmarketplacebadges.dev/installs/weaveworks.vscode-gitops-tools.png)](https://marketplace.visualstudio.com/items?itemName=Weaveworks.vscode-gitops-tools)
[![VSCode Marketplace Link](https://img.shields.io/visual-studio-marketplace/v/weaveworks.vscode-gitops-tools)](https://marketplace.visualstudio.com/items?itemName=Weaveworks.vscode-gitops-tools)
[![Install Counter](https://img.shields.io/visual-studio-marketplace/i/weaveworks.vscode-gitops-tools)](https://marketplace.visualstudio.com/items?itemName=Weaveworks.vscode-gitops-tools)

Weaveworks [GitOps Tools Extension](https://marketplace.visualstudio.com/items?itemName=Weaveworks.vscode-gitops-tools) provides an intuitive way to manage, troubleshoot and operate your Kubernetes environment following the GitOps operating model. GitOps accelerates your development lifecycle and simplifies your continuous delivery pipelines. The extension is built on Flux (a CNCF open source project). To learn more about the Flux GitOps toolkit, visit [fluxcd.io]

Expand All @@ -27,12 +27,15 @@ There are a few requirements before installing and using the extension:

Once you have satisfied these requirements you can find and install GitOps Tools in the [Extension Marketplace](https://marketplace.visualstudio.com/items?itemName=Weaveworks.vscode-gitops-tools) by searching for "**fluxcd**" or "**gitops**".

### kubectl proxy

This extension uses two different methods to get information from the Kubernetes cluster. It preferentially will run `kubectl proxy -p 0` for your selected cluster and will use the proxy with a javascript client for faster performance and real-time updates. This also requires `watch` RBAC for Flux resources. If the proxy client connection can't be established the extension will fall back to `kubectl get` for querying the cluster.


# Features
- Configure, visualize and manage Flux resources
- Tree views for Clusters, Sources, and Workloads
- Observe Flux resource updates in the cluster in real-time
- Select clusters and examine installed [GitOps Toolkit components](https://fluxcd.io/docs/components/)
- Enable and Disable GitOps (install/uninstall Flux) on clusters
- Create, view and edit sources (git, OCI, Helm and Bucket), and workloads (Kustomization and HelmRelease)
Expand All @@ -42,6 +45,7 @@ Once you have satisfied these requirements you can find and install GitOps Tools
- Clone GitRepository source to user machine and open them in the editor
- Preview sources, workloads and other objects information with tooltips
- Open remote resources as `.yaml` files in the editor
- Open and edit the kubeconfig file
- Trace Kubernetes objects created by workloads
- Watch Flux controller logs and `flux` CLI commands for diagnostics
- Documentation links for [Flux](https://fluxcd.io/docs) and [Weave GitOps](https://docs.gitops.weave.works/docs/intro/) embedded in the extension
Expand Down Expand Up @@ -121,17 +125,37 @@ The GitOps Tools Extension depends on the [Kubernetes Tools](https://marketplace
- Make sure you have [successfully authenticated](https://docs.microsoft.com/en-us/cli/azure/authenticate-azure-cli) on your `az` CLI and have access to the [correct subscription](https://docs.microsoft.com/en-us/cli/azure/account?view=azure-cli-latest#az_account_set) for your AKS or ARC cluster.
- The easiest way to get your AKS or Arc cluster visible by the GitOps and Kubernetes Extensions, is to use the `az` CLI to merge the kubeconfig for accessing your cluster onto the default `kubectl` config. Use `get-credentials` as shown in the [official CLI documentation](https://docs.microsoft.com/en-us/cli/azure/aks?view=azure-cli-latest#az_aks_get_credentials). In order to enable GitOps in a cluster you will likely need the `--admin` credentials.

## Weave GitOps Enterprise (WGE) Templates
## Weave GitOps Enterprise (WGE) Integration

WGE users can access GitOpsTemplates directly from this extensions. Templates are provided by cluster administrators (Platform Teams) and can be used to quickly create cluster and configure applications with GitOps.
WGE users can access GitOpsTemplates directly from this extensions. WGE integration adds another treeview that shows `GitOpsTemplate`, `Canary`, `Pipeline`, and `GitOpsSet` resources and adds new interactions to each type of resource. All WGE resources have a right-click action to open them in WGE portal.

Templates are an opt-in feature that must be enabled in setting:
GitOpsTemplates are provided by cluster administrators (Platform Teams) and can be used to quickly create cluster and configure applications with GitOps. Flagger Canaries status can be visualized and their progress tracked. Pipelines are listed with their targets and each `GitopsCluster` attached to a Pipeline can be set as the current selected cluster for quick navigation between clusters.

![Enable GitOpsTemplates](docs/images/vscode-templates-config.png)
WGE integration is an opt-in feature that must be enabled in settings:

After that they can be seen in a new 'Templates' view. Right-click a template to use it:
![Enable WGE Features](docs/images/config-enable-wge.png)

![Weave GitOps Treeview](docs/images/weave-gitops-treeview.png)

![Create GitOps Template](docs/images/vscode-templates-view.png)

### WGE Configuration

For the integration to work, this extension needs a ConfigMap that provides WGE information and settings:

`kubectl create configmap weave-gitops-interop --from-literal=portalUrl='https://WGE-CLUSTER-HOST' --from-literal=wgeClusterName='WGE-CLUSTER-NAME' -n flux-system``

```
apiVersion: v1
kind: ConfigMap
metadata:
namespace: flux-system
name: weave-gitops-interop
data:
portalUrl: https://mccp.howard.moomboo.space
wgeClusterName: howard-moomboo-space
```

![Use GitOpsTemplates](docs/images/vscode-templates-view.png)



Expand All @@ -145,10 +169,15 @@ We rely on the Kubernetes extension to discover and connect to clusters. If you

Confirm that your configuration context shows in a terminal running `kubectl config get-contexts`

### _Switching from an unreachable cluster context to a working cluster_

Unreachable or laggy clusters can create long running that cluster resource queries that finish after switching to a working cluster context. This can lead to the slow cluster data overwriting the current cluster treeview. **Clusters** -> **Refresh** button will reinitialize the views with current data. Timeout settings can be adjusted under **GitOps** section in VSCode Settings.

### _Timeouts and flux check warnings_

The extension has timeout options that can make be adjusted in VSCode settings to match your cluster network constraints. The default timeout for any data query operation is 60 seconds.

`flux check` command can also be disabled in the settings. This will stop `flux check` warnings about old versions but will disable Flux controller status icons in the the Clusters treeview.


# Data and Telemetry
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "vscode-gitops-tools",
"displayName": "GitOps Tools for Flux",
"description": "GitOps automation tools for continuous delivery of Kubernetes and Cloud Native applications",
"version": "0.24.3",
"version": "0.26.0",
"author": "Kingdon Barrett <[email protected]>",
"contributors": [
"Kingdon Barrett <[email protected]>",
Expand Down

0 comments on commit 404fe19

Please sign in to comment.