Skip to content

Commit f976e40

Browse files
committed
Switch from wget to curl for websocat download (handles GitHub redirects)
1 parent 6323716 commit f976e40

2 files changed

Lines changed: 8 additions & 8 deletions

File tree

docs/sandbox/ssh-access.mdx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ ssh -o 'ProxyCommand=websocat --binary -B 65536 - wss://8081-%h.e2b.app' <sandbo
2424
<Tab title="Linux">
2525
```bash
2626
# Install websocat
27-
sudo wget -qO /usr/local/bin/websocat https://github.com/vi/websocat/releases/latest/download/websocat.x86_64-unknown-linux-musl
27+
sudo curl -fsSL -o /usr/local/bin/websocat https://github.com/vi/websocat/releases/latest/download/websocat.x86_64-unknown-linux-musl
2828
sudo chmod a+x /usr/local/bin/websocat
2929

3030
# Connect to your sandbox
@@ -80,9 +80,9 @@ You can either build a [custom template](/docs/template/examples/ssh-ready) or s
8080

8181
```bash
8282
# Install SSH server and websocat
83-
sudo apt-get update && sudo apt-get install -y openssh-server
83+
sudo apt-get update && sudo apt-get install -y openssh-server curl
8484
sudo mkdir -p /run/sshd
85-
sudo wget -qO /usr/local/bin/websocat https://github.com/vi/websocat/releases/latest/download/websocat.x86_64-unknown-linux-musl
85+
sudo curl -fsSL -o /usr/local/bin/websocat https://github.com/vi/websocat/releases/latest/download/websocat.x86_64-unknown-linux-musl
8686
sudo chmod a+x /usr/local/bin/websocat
8787

8888
# Set a password for the user
@@ -105,7 +105,7 @@ brew install websocat
105105
</Tab>
106106
<Tab title="Linux">
107107
```bash
108-
sudo wget -qO /usr/local/bin/websocat https://github.com/vi/websocat/releases/latest/download/websocat.x86_64-unknown-linux-musl
108+
sudo curl -fsSL -o /usr/local/bin/websocat https://github.com/vi/websocat/releases/latest/download/websocat.x86_64-unknown-linux-musl
109109
sudo chmod a+x /usr/local/bin/websocat
110110
```
111111
</Tab>

docs/template/examples/ssh-ready.mdx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@ import { Template, waitForPort } from 'e2b'
1414
export const template = Template()
1515
.fromUbuntuImage('22.04')
1616
// Install SSH server and websocat for WebSocket proxying
17-
.aptInstall(['openssh-server', 'wget'])
17+
.aptInstall(['openssh-server', 'curl'])
1818
.runCmd([
19-
'wget -qO /usr/local/bin/websocat https://github.com/vi/websocat/releases/latest/download/websocat.x86_64-unknown-linux-musl',
19+
'curl -fsSL -o /usr/local/bin/websocat https://github.com/vi/websocat/releases/latest/download/websocat.x86_64-unknown-linux-musl',
2020
'chmod a+x /usr/local/bin/websocat',
2121
])
2222
// Configure SSH with password authentication
@@ -37,9 +37,9 @@ template = (
3737
Template()
3838
.from_ubuntu_image("22.04")
3939
# Install SSH server and websocat for WebSocket proxying
40-
.apt_install(["openssh-server", "wget"])
40+
.apt_install(["openssh-server", "curl"])
4141
.run_cmd([
42-
"wget -qO /usr/local/bin/websocat https://github.com/vi/websocat/releases/latest/download/websocat.x86_64-unknown-linux-musl",
42+
"curl -fsSL -o /usr/local/bin/websocat https://github.com/vi/websocat/releases/latest/download/websocat.x86_64-unknown-linux-musl",
4343
"chmod a+x /usr/local/bin/websocat",
4444
])
4545
# Configure SSH with password authentication

0 commit comments

Comments
 (0)