Connor Peet and GitHub
c8718e7290
cli: shut down service on windows more reliably ( #181584 )
...
* cli: shut down service on windows more reliably
Use the singleton kill logic.
Fixes #175268
* fix lint
2023-05-04 14:56:09 -07:00
Connor Peet and GitHub
8b28c834bb
cli: do not set tunnel mutex when running from service only ( #181574 )
...
Fixes #181525
2023-05-04 21:11:33 +02:00
Connor Peet and GitHub
5a139d4ffc
cli: fix tunnel names are case sensitive but remoteAuthorities are not ( #181347 )
...
Fixes #177222
2023-05-02 18:55:11 +02:00
Connor Peet and GitHub
d54402822a
cli: fix mutex names contain extra characters ( #181335 )
...
Fixes #181334
2023-05-02 17:16:17 +02:00
Connor Peet and GitHub
06ff8779bd
cli: tunnels can sporadically become unresponsive ( #181285 )
...
Last iteration I moved some RPC logic to use Tokios "codecs" to give
them cancellation safety. These operate on streams of input data.
While this worked at first, I failed to take into account that the byte
buffer we read from the stream could have _more_ data than just the
current message under load scenarios. We were discarding any extra data
from the subsequent message. In most cases caused the next message
"length" to be read from the middle of the next message, which usually
(when parsed as a u32) was some number of gigabytes, then causing the
connection to stall forever.
Fixes #181284
2023-05-01 17:34:11 -07:00
Connor Peet and GitHub
cda21c19a7
cli: fix attach does not always work ( #181273 )
...
* fix: don't sync debug.lastExtensionDevelopmentWorkspace
* cli: fix attach does not always work
Seems like reading stdin when it's open but never written to blocks the process. Fix that, both by checking IS_INTERACTIVE_CLI before reading stdin, and by not passing stdin to the tunnel subprocess.
Fixes #179122
2023-05-01 14:58:25 -07:00
Connor Peet and GitHub
43e0111e14
cli: only show other interactive attach commands when in a terminal ( #181163 )
...
* testing: another fix to avoid automatically queuing
Fixes #180041 again
* cli: only show other interactive attach commands when in a terminal
Fixes #178091
2023-04-28 15:13:26 -07:00
Connor Peet and GitHub
ab6ba2ebee
cli: fix problem restarting tunnel with uppercase letter in name ( #180881 )
...
Fixes #180693
2023-04-25 23:50:15 +02:00
Connor Peet and GitHub
cedf1eaa25
cli: add new control server messages for wsl ( #180438 )
...
* cli: add new control server messages for wsl
* support cwd in spawn
2023-04-20 15:19:05 -07:00
Benjamin Pasero and GitHub
6d5b85427d
debt - remove unsupported max_old_space_size option ( #180183 )
2023-04-17 22:32:23 -07:00
Connor Peet and GitHub
34f65dc1d7
cli: update hyper for cg ( #180135 )
2023-04-17 10:19:53 -07:00
1e774371f2
Bump h2 from 0.3.14 to 0.3.17 in /cli ( #179890 )
...
Bumps [h2](https://github.com/hyperium/h2 ) from 0.3.14 to 0.3.17.
- [Release notes](https://github.com/hyperium/h2/releases )
- [Changelog](https://github.com/hyperium/h2/blob/master/CHANGELOG.md )
- [Commits](https://github.com/hyperium/h2/compare/v0.3.14...v0.3.17 )
---
updated-dependencies:
- dependency-name: h2
dependency-type: indirect
...
Signed-off-by: dependabot[bot] <support@github.com >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-04-15 21:11:48 -07:00
Connor Peet and GitHub
f743297aa1
cli: add acquire_cli ( #179837 )
...
* cli: add acquire_cli
As given in my draft document, pipes a CLI of the given platform to the
specified process, for example:
```js
const cmd = await rpc.call('acquire_cli', {
command: 'node',
args: [
'-e',
'process.stdin.pipe(fs.createWriteStream("c:/users/conno/downloads/hello-cli"))',
],
platform: Platform.LinuxX64,
quality: 'insider',
});
```
It genericizes caching so that the CLI is also cached on the host, just
like servers.
* fix bug
2023-04-13 19:18:48 +01:00
Connor Peet and GitHub
ca9404bd2f
cli: read tunnel lock from product.json ( #179800 )
...
Fixes #179265
2023-04-12 18:52:37 +01:00
Connor Peet and GitHub
4180bbd21e
cli: fix macos build ( #179794 )
2023-04-12 18:33:29 +02:00
Connor Peet and GitHub
2d8ff25c85
cli: add streams to rpc, generic 'spawn' command ( #179732 )
...
* cli: apply improvements from integrated wsl branch
* cli: add streams to rpc, generic 'spawn' command
For the "exec server" concept, fyi @aeschli.
* update clippy and apply fixes
* fix unused imports :(
2023-04-12 16:51:29 +01:00
Connor Peet and GitHub
b547b58db6
cli: use win32 app mutex to detect running tunnels and tunnel sevices ( #179622 )
...
* cli: fix distro mixin
* cli: use win32 app mutex to detect running tunnels and tunnel sevices
Fixes #179265
* cli: fix distro mixin more
* fix
* fix build
2023-04-10 20:25:14 +01:00
29d93918d2
Bump openssl from 0.10.42 to 0.10.48 in /cli ( #178296 )
...
Bumps [openssl](https://github.com/sfackler/rust-openssl ) from 0.10.42 to 0.10.48.
- [Release notes](https://github.com/sfackler/rust-openssl/releases )
- [Commits](https://github.com/sfackler/rust-openssl/compare/openssl-v0.10.42...openssl-v0.10.48 )
---
updated-dependencies:
- dependency-name: openssl
dependency-type: indirect
...
Signed-off-by: dependabot[bot] <support@github.com >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-03-28 08:20:29 -07:00
Connor Peet and GitHub
dfbea0f578
cli: when attaching, always print the connection link ( #178445 )
...
Fixes #178090
2023-03-27 12:52:50 -07:00
Connor Peet and GitHub
b51e2f3613
cli: only connect to existing tunnel process when quality is the same ( #178446 )
...
Fixes #178089
2023-03-27 12:11:18 -07:00
Connor Peet and GitHub
792114a7ec
cli: rename tunnels to lowercase names ( #178272 )
...
* cli: rename tunnels to lowercase names
Fixes #177222
* fix lint
2023-03-25 19:43:53 -07:00
Connor Peet and GitHub
f299f6f423
cli: fix windows terminal erroring on tunnel first run ( #178267 )
...
* cli: fix tunnel message command
Fixes #177394
* fix: windows terminal erroring on tunnel first run
Was fixed by https://github.com/console-rs/dialoguer/pull/192
Fixes #175747
2023-03-24 15:46:42 -07:00
Connor Peet and GitHub
97af9cd323
cli: only show Ctrl+C to detach when in a terminal ( #178276 )
...
Fixes #178091
2023-03-24 15:46:16 -07:00
Connor Peet and GitHub
3d7f6dec00
cli: fix tunnel message command ( #178079 )
...
Fixes #177394
2023-03-22 14:44:49 -07:00
Connor Peet and GitHub
349c62ab30
cli: fix reading of client tunnel commands ( #177919 )
...
.read_line() appends to the string, so this caused the first command entered to always be read again
2023-03-21 16:33:28 -07:00
Connor Peet and GitHub
b9c2df39d1
cli: don't colorize file log output, collect internal logs for broadcast ( #177420 )
...
Fixes #177345
2023-03-17 17:14:41 +01:00
Connor Peet and GitHub
120d0d2fdb
fix: make tunnel names case-insensitive ( #177413 )
...
Lowercase them, since Basis internally is case-sensitive.
Fixes #177222
2023-03-16 15:49:51 -07:00
Connor Peet and GitHub
9fc16337d5
cli: code-insiders tunnel service install message should use code-insiders ( #177394 )
...
Fixes #177344
2023-03-16 21:18:22 +01:00
Connor Peet and GitHub
eab8ba65bf
cli: add tunnel status command ( #177381 )
...
Fixes #177372
2023-03-16 12:26:56 -07:00
Connor Peet and GitHub
025e3194e1
fix: missing accept server license terms arg in service install ( #177366 )
...
Fixes #177351
2023-03-16 11:23:35 -07:00
Connor Peet and GitHub
0e1ec3e87d
fix: not installing extensions in the directory that is being passed ( #177303 )
...
Fixes https://github.com/microsoft/vscode-internalbacklog/issues/3595
2023-03-16 00:14:53 +01:00
Connor Peet and GitHub
abab52dd94
cli: add tunnel kill/restart subcommands ( #177286 )
2023-03-15 15:09:12 -07:00
Connor Peet and GitHub
0e7d14d32d
cli: allow client process to control singleton process ( #177141 )
...
Other connected clients will now print:
```
Connected to an existing tunnel process running on this machine. You can press:
- Ctrl+C to detach
- "x" to stop the tunnel and exit
- "r" to restart the tunnel
```
These are then sent to the server to have that take effect. This is
mostly some refactors in the singleton_server to make the lifecycle work.
2023-03-14 17:55:28 -07:00
Connor Peet and GitHub
1b5fd140fb
Run tunnels as singleton process (for a --cli-data-dir) ( #177002 )
...
* wip on singleton
* wip
* windows support
* wip
* wip
* fix clippy
2023-03-14 08:09:47 -07:00
Connor Peet and GitHub
863b9261a3
cli: bump tempfile->remove_dir_all for cve ( #176206 )
2023-03-06 10:10:01 +01:00
ef46983a3a
cli: option to disable encryption of keychain matter
...
* option to disable encryption of keys
Avoids issue of token invalidation when switching machines with a shared home directory, as suggested by @connor4312 in https://github.com/microsoft/vscode-remote-release/issues/8110#issuecomment-1452270922
Fixes #8110
* Update cli/src/auth.rs
Co-authored-by: Connor Peet <connor@peet.io >
* Change variable to VSCODE_CLI_DISABLE_KEYCHAIN_ENCRYPT
Co-authored-by: Connor Peet <connor@peet.io >
---------
Co-authored-by: Connor Peet <connor@peet.io >
2023-03-02 20:28:57 +01:00
Connor Peet and GitHub
26fe31fc66
update openssl-prebuild for musl failures ( #175731 )
...
* update openssl-prebuild for musl failures
* reapply vendoring
* reapply macos pipeline fix
2023-03-01 08:57:45 +01:00
Connor Peet and GitHub
f8119e9beb
Revert "cli: fix static import of openssl ( #175681 )" ( #175727 )
...
This reverts commit 7014a17b1f .
2023-03-01 07:43:32 +01:00
Connor Peet and GitHub
7014a17b1f
cli: fix static import of openssl ( #175681 )
...
* cli: fix static import of openssl
* update dev tunnels
2023-02-28 11:20:58 -08:00
Benjamin Pasero
2cad803acf
Revert "Bump openssl-src from 111.22.0+1.1.1q to 111.25.0+1.1.1t in /cli ( #173883 )"
...
This reverts commit be0f82c93a .
2023-02-28 08:37:33 +01:00
be0f82c93a
Bump openssl-src from 111.22.0+1.1.1q to 111.25.0+1.1.1t in /cli ( #173883 )
...
Bumps [openssl-src](https://github.com/alexcrichton/openssl-src-rs ) from 111.22.0+1.1.1q to 111.25.0+1.1.1t.
- [Release notes](https://github.com/alexcrichton/openssl-src-rs/releases )
- [Commits](https://github.com/alexcrichton/openssl-src-rs/commits )
---
updated-dependencies:
- dependency-name: openssl-src
dependency-type: indirect
...
Signed-off-by: dependabot[bot] <support@github.com >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-02-27 16:05:56 +00:00
Martin Aeschlimann and GitHub
beb9ed3758
update tokio ( #173784 )
2023-02-08 17:10:14 +07:00
Connor Peet and GitHub
40f31f92d0
cli: fix download for arm32 linux ( #173374 )
...
Once again, wishing target_* were statically typed...
Fixes https://github.com/microsoft/vscode-remote-release/issues/7631
2023-02-03 13:30:31 -08:00
Connor Peet and GitHub
760c998cda
cli: remove debug print ( #173223 )
2023-02-02 15:32:47 -08:00
Connor Peet and GitHub
953a039549
cli: use hostname-based generation instead of bird names ( #173220 )
...
Fixes #167708 by using a more predictable naming scheme.
```
me> Write a haiku about the extinction of birds
chatgpt>
Silent skies above,
Once lively songs now gone,
Fading memories.
```
2023-02-02 15:05:38 -08:00
Connor Peet and GitHub
339fd630e6
cli: fix macos build ( #172712 )
2023-01-28 17:43:32 -08:00
Connor Peet and GitHub
b5aa3e0a3d
cli: use better approach to Windows services ( #172679 )
...
Fixes #167741
This eschews the offical Windows service system in favor of registering
into `HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run`.
Unlike services, this can be done without administrative permissions,
does not require the current username/password, and is not blocked by
miscellaneous and mysterious system policies.
Since the process is basically unmanaged by the OS, this requires a
little legwork to start and stop the process when registering and
unregistering.
2023-01-27 15:04:56 -08:00
Connor Peet and GitHub
7a04589c16
cli: fix sleep inhibition not always working ( #172428 )
...
Seems like we should prevent _both_ "useridlesystemsleep" as well as "systemsleep"
Fixes https://github.com/microsoft/vscode-remote-release/issues/7913
2023-01-25 19:50:52 +01:00
Connor Peet and GitHub
5beebeb170
cli: fall back to screensaver api for linux no-sleep ( #172353 )
2023-01-25 16:28:30 +09:00
Connor Peet and GitHub
618da1e00a
cli: fix arch check for musl arm64 ( #172092 )
...
Fixes https://github.com/microsoft/vscode-remote-release/issues/7812
Wish Rust had compilation errors for bad compile time checks :(
2023-01-23 16:50:24 -08:00