

0 / 2 embers
0 / 3000 xp
click for more info
Complete a lesson to start your streak
click for more info
Difficulty: 3
click for more info
Not enough gems
Cost: 6 gems
1: Learn AI Coding
incomplete
2: Chat, Autocomplete, and Agents
incomplete
3: Installing OpenCode
incomplete
4: OpenCode Console
incomplete
5: The Unix Philosophy
incomplete
6: OpenCode Config
incomplete
7: CLI Config
incomplete
8: OpenCode Run
incomplete
9: GUI Clients
incomplete
10: Mobile Usage
incomplete
11: Remote Server
incomplete
Back
ctrl+,
Next
ctrl+.
This lesson's interactive features are locked, please to keep using them
You can also use a remote computer to run your OpenCode sessions. It doesn't need to be your local machine, it can be a cloud VM, a Raspberry Pi, or any other computer you have access to!
To set up OpenCode on another server, ssh into it and run the following command to start the OpenCode server:
OPENCODE_PASSWORD="<password>" opencode serve --hostname 0.0.0.0 --port 4096
OpenCode prints its listening address, and you can stop the server anytime with Ctrl+C.
Then, to connect to the remote server from your local machine, run:
OPENCODE_PASSWORD="<password>" opencode --server http://<hostname>:4096
Replacing the <password> and the <hostname> with your own, of course.
Then, file access and shell commands run on the host machine with the server user's permissions. Be sure to use an encrypted connection like Tailscale or an SSH tunnel; a password alone still does not encrypt regular HTTP traffic.
You may have heard of OpenClaw, a harness that integrates with messaging apps like Slack and Discord, and which can use OpenCode under the hood via the Agent Client Protocol (ACP). While it's out of scope for this course, I just want to point out how we're using it internally. Here at Boot.dev, we have a read-only OpenClaw agent running 24/7 on a private cloud VM.
This allows me to @BootsAgent in Discord and ask, "How many users signed up yesterday?" or "What's the failure rate for lesson 5.4 of the Python course?" and get a quick answer in a shared team channel!