Benchdog Shell
A VS Code extension that opens Azure Cloud Shell, Bash or PowerShell, in a VS Code terminal tab, signed in as you, so there is no need to keep shell.azure.com open in a browser. It is the same Cloud Shell, with your clouddrive files and every tool Cloud Shell has. It also opens local terminals for az, puts your subscriptions a click away, and keeps the one line commands you run often. All the work is done by the Benchdog engine (benchdog serve); this extension is the screen.
Install
Install it from the Marketplace in VS Code. The Benchdog engine ships inside the package for Windows (x64), so there is nothing else to install and no .NET needed. Mac and Linux are coming. The desktop app and the benchdog command for the same tool are at benchdog.dev.
What it does
- Cloud Shell tabs: open the Shell panel in the activity bar and click Cloud Shell (Bash) or Cloud Shell (PowerShell), or pick Benchdog: Cloud Shell from the terminal's + menu. The tab shows each step while Cloud Shell starts, then the shell itself: colours, Tab completion, the arrows, Ctrl+C, vim and top all work, and the tab tells Cloud Shell when it changes size. Keys typed while it starts are kept and sent once it is ready. Open as many tabs as you like; each is its own terminal on your one Cloud Shell. Typing exit, Cloud Shell's own idle timeout or a lost connection ends the tab with what happened, and the next key closes it.
- Local terminals: Local Terminal opens a terminal on your machine and runs
az account show --output table, so you see who az is signed in as. If az is not installed, it offers the install page or a Cloud Shell tab instead, which has az already.
- Subscriptions: the Subscriptions group lists the subscriptions your Benchdog account can see, enabled ones first. Click one to make it the current subscription in the active terminal:
az account set --subscription <id>, and in a PowerShell Cloud Shell Set-AzContext as well, so az and the Az module agree. Right-click to copy its id.
- Saved commands: keep the single line commands you run often, such as
az group list --output table. Click one to paste it into the active terminal without running it, or press its play button to run it. With no terminal open, it asks which kind to open first. Commands are kept as plain text in VS Code, so the extension warns before saving one that looks as if it holds a password, key or token.
- Sign in works as in the other Benchdog tools: your Benchdog account through the browser once, or your existing
az login with benchdogShell.useAzureCli. Cloud Shell runs as that account.
First time
Cloud Shell needs setting up once per account, in the browser: open https://shell.azure.com, choose Bash or PowerShell, and choose how to keep files. Until then, a Cloud Shell tab says so. After that, the browser is not needed again.
Settings
| Setting |
Does |
benchdogShell.enginePath |
Full path to the benchdog executable. Empty uses the one that ships with the extension. |
benchdogShell.tenant |
Tenant id to open Cloud Shell and list subscriptions in. Empty means your home tenant. |
benchdogShell.useAzureCli |
Sign in through your existing az login instead of the browser. |
benchdogShell.defaultShell |
The shell Open Cloud Shell opens: the one you chose in Cloud Shell (the default), Bash or PowerShell. |
benchdogShell.localStartCommand |
A one line command run when a local terminal opens. Empty runs nothing. |
benchdogShell.diagnostics |
Write a diagnostics log of what the engine does. See Diagnostics below. |
The settings are separate from the other Benchdog extensions', so they can all be installed together.
How it stays safe
- Cloud Shell runs as you, with a token the engine asks for and never shows, logs or hands to the extension. The extension only ever sees what the shell prints.
- What you type and what the shell prints are never written to the diagnostics log, the output channel or anywhere else.
- Saved commands are kept in VS Code's storage as plain text, never a password on purpose: the extension warns before saving one that looks as if it holds a secret.
- Keys go to Cloud Shell one request at a time, in the order typed, so a fast paste never arrives mixed up.
Diagnostics
Turn on the benchdogShell.diagnostics setting to have the engine write a debug log of what it does, for finding out why something went wrong. Run Benchdog Shell: Open Diagnostics Logs Folder to see the logs. Passwords, tokens, what you type and what the shell prints are never written.
Trial and licence
Every Benchdog tool has a thirty day trial with every feature and no card: ask for one at benchdog.dev/trial. One licence is for one person and covers the VS Code extension, the desktop app and the command line, on every machine you work from. Prices are at benchdog.dev/pricing. The licence is checked offline; the tool contacts benchdog.dev only when you ask it to, never in the background. The terms are in LICENSE.md and at benchdog.dev/terms.
Help and support
Getting started, how to do the common jobs, the questions people ask and what to try when something goes wrong: benchdog.dev/help/shell. Something else? The support form, or support@benchdog.dev, and a person replies.