Skip to content

Commit

Permalink
Initial webview (#22)
Browse files Browse the repository at this point in the history
* move kubectl command output to webview

* move all commands into webview
  • Loading branch information
peterbom committed Sep 12, 2023
1 parent 65142b9 commit facac37
Show file tree
Hide file tree
Showing 20 changed files with 664 additions and 359 deletions.
2 changes: 1 addition & 1 deletion .vscode/tasks.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
"fileLocation": "absolute",
"background": {
"activeOnStart": true,
"beginsPattern": "^.* page reload .*",
"beginsPattern": "^(?:.* page reload |\\[TypeScript\\]).*",
"endsPattern": "^.*\\[TypeScript\\].*"
},
"pattern": [
Expand Down
125 changes: 26 additions & 99 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,26 @@
"default": "v0.19.0",
"title": "Kubectl-gadget repository release tag",
"description": "Release tag for the stable kubectl-gadget tool."
},
"azure.customkubectl.commands": {
"type": "array",
"title": "Custom Kubectl commands",
"items": {
"type": "object",
"title": "A kubectl command",
"properties": {
"name": {
"type": "string",
"description": "Name for the command"
},
"command": {
"type": "string",
"description": "The command (minus 'kubectl' prefix)"
}
}
},
"default": [],
"description": "All the custom kubectl commands"
}
}
},
Expand Down Expand Up @@ -184,30 +204,6 @@
"command": "aks.createClusterNavToAzurePortal",
"title": "Create Cluster From Azure Portal"
},
{
"command": "aks.aksKubectlGetPodsCommands",
"title": "Get All Pods"
},
{
"command": "aks.aksKubectlGetClusterInfoCommands",
"title": "Get Cluster Info"
},
{
"command": "aks.aksKubectlGetAPIResourcesCommands",
"title": "Get API Resources"
},
{
"command": "aks.aksKubectlGetNodeCommands",
"title": "Get Nodes"
},
{
"command": "aks.aksKubectlDescribeServicesCommands",
"title": "Describe Services"
},
{
"command": "aks.aksKubectlGetEventsCommands",
"title": "Get All Events"
},
{
"command": "aks.aksDeleteCluster",
"title": "Delete Cluster"
Expand All @@ -216,29 +212,17 @@
"command": "aks.aksRotateClusterCert",
"title": "Rotate Cluster Certificate"
},
{
"command": "aks.aksKubectlK8sHealthzAPIEndpointCommands",
"title": "Healthz check"
},
{
"command": "aks.aksKubectlK8sLivezAPIEndpointCommands",
"title": "Livez check"
},
{
"command": "aks.aksKubectlK8sReadyzAPIEndpointCommands",
"title": "Readyz check"
},
{
"command": "aks.aksInspektorGadgetShow",
"title": "Show Inspektor Gadget"
},
{
"command": "aks.createCluster",
"title": "Create Standard Cluster"
"command": "aks.aksRunKubectlCommands",
"title": "Run Kubectl Commands"
},
{
"command": "aks.aksCustomKubectlCommand",
"title": "Run Custom Kubectl Command"
"command": "aks.createCluster",
"title": "Create Standard Cluster"
}
],
"menus": {
Expand Down Expand Up @@ -287,19 +271,14 @@
"submenu": "aks.createClusterSubMenu",
"when": "view == kubernetes.cloudExplorer && viewItem =~ /aks\\.subscription/i"
},
{
"submenu": "aks.runKubectlCmdSubMenu",
"when": "view == kubernetes.cloudExplorer && viewItem =~ /aks\\.cluster/i",
"group": "9@1"
},
{
"submenu": "aks.managedClusterOperationSubMenu",
"when": "view == kubernetes.cloudExplorer && viewItem =~ /aks\\.cluster/i",
"group": "9@3"
},
{
"submenu": "aks.K8sAPIEndpointHealthCheck",
"when": "view == kubernetes.cloudExplorer && viewItem =~ /aks\\.cluster/i",
"command": "aks.aksRunKubectlCommands",
"when": "view == kubernetes.cloudExplorer && viewItem =~ /aks\\.cluster/i || view == extension.vsKubernetesExplorer && viewItem =~ /vsKubernetes\\.\\w*cluster$/i",
"group": "9@3"
},
{
Expand Down Expand Up @@ -362,36 +341,6 @@
"group": "navigation"
}
],
"aks.runKubectlCmdSubMenu": [
{
"command": "aks.aksKubectlGetPodsCommands",
"group": "navigation"
},
{
"command": "aks.aksKubectlGetClusterInfoCommands",
"group": "navigation"
},
{
"command": "aks.aksKubectlGetAPIResourcesCommands",
"group": "navigation"
},
{
"command": "aks.aksKubectlGetNodeCommands",
"group": "navigation"
},
{
"command": "aks.aksKubectlDescribeServicesCommands",
"group": "navigation"
},
{
"command": "aks.aksKubectlGetEventsCommands",
"group": "navigation"
},
{
"command": "aks.aksCustomKubectlCommand",
"group": "navigation"
}
],
"aks.managedClusterOperationSubMenu": [
{
"command": "aks.aksDeleteCluster",
Expand All @@ -401,20 +350,6 @@
"command": "aks.aksRotateClusterCert",
"group": "navigation"
}
],
"aks.K8sAPIEndpointHealthCheck": [
{
"command": "aks.aksKubectlK8sHealthzAPIEndpointCommands",
"group": "navigation"
},
{
"command": "aks.aksKubectlK8sLivezAPIEndpointCommands",
"group": "navigation"
},
{
"command": "aks.aksKubectlK8sReadyzAPIEndpointCommands",
"group": "navigation"
}
]
},
"submenus": [
Expand All @@ -426,18 +361,10 @@
"id": "aks.ghWorkflowSubMenu",
"label": "Create GitHub Workflow"
},
{
"id": "aks.runKubectlCmdSubMenu",
"label": "Run Kubectl Commands"
},
{
"id": "aks.managedClusterOperationSubMenu",
"label": "Managed Cluster Operations"
},
{
"id": "aks.K8sAPIEndpointHealthCheck",
"label": "Kubernetes API Health Endpoints"
},
{
"id": "aks.createClusterSubMenu",
"label": "Create Cluster"
Expand Down
48 changes: 0 additions & 48 deletions resources/webviews/aksKubectlCommand/akskubectlcommand.html

This file was deleted.

48 changes: 0 additions & 48 deletions src/commands/aksKubectlCommands/aksCustomiseKubectlCommand.ts

This file was deleted.

Loading

0 comments on commit facac37

Please sign in to comment.