Skip to content

Commit 04398ea

Browse files
committed
docs(installation): document snap install path
Signed-off-by: Zygmunt Krynicki <zygmunt.krynicki@canonical.com>
1 parent 8d6bb82 commit 04398ea

1 file changed

Lines changed: 78 additions & 2 deletions

File tree

‎docs/about/installation.mdx‎

Lines changed: 78 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,10 @@ Install OpenShell with a single command:
1616
curl -LsSf https://raw.githubusercontent.com/NVIDIA/OpenShell/main/install.sh | sh
1717
```
1818

19-
The script detects your operating system and installs the OpenShell CLI and gateway with your native package manager. It then starts the local gateway server so you can begin creating sandboxes.
19+
The script detects your operating system and installs the OpenShell CLI and
20+
gateway. On Linux, the Snap path is preferred when `snapd` is available;
21+
otherwise the script uses the native DEB or RPM package. The gateway then
22+
starts automatically so you can begin creating sandboxes.
2023

2124
You can also download release artifacts directly from the [OpenShell GitHub Releases](https://github.com/NVIDIA/OpenShell/releases) page.
2225

@@ -51,6 +54,13 @@ brew services restart openshell
5154

5255
## Linux
5356

57+
On distributions that ship with `snapd`, the install script uses the Snap path
58+
described below, provided no non-snap Docker is detected. If a native Docker
59+
package is present, the installer exits with an error and recommends installing
60+
via DEB or RPM instead. On hosts without `snapd` (or with
61+
`OPENSHELL_INSTALL_METHOD=classic` set), the script falls back to the classic
62+
package manager.
63+
5464
On Fedora and RHEL, the install script uses RPM packages. The RPM installs the `openshell` CLI, the `openshell-gateway` daemon, and a systemd user service.
5565

5666
On Debian and Ubuntu, the install script uses a Debian package. The Debian package installs the `openshell` CLI, the `openshell-gateway` daemon, VM sandbox support, and a systemd user service.
@@ -77,7 +87,12 @@ sudo loginctl enable-linger $USER
7787

7888
## Snap
7989

80-
Install the OpenShell snap from the Snap Store:
90+
On Linux distributions that ship with `snapd`, the install script installs
91+
OpenShell from the Snap Store. The OpenShell snap bundles the CLI, the terminal
92+
UI, and a managed gateway daemon. snapd handles upgrades and rollback; the
93+
gateway runs as a system service inside the snap.
94+
95+
You can also install the snap directly:
8196

8297
```shell
8398
sudo snap install openshell --classic
@@ -89,6 +104,14 @@ stores its database at `$SNAP_COMMON/gateway.db` (typically
89104
`/var/snap/openshell/common/gateway.db`). Create `$SNAP_COMMON/gateway.toml`
90105
when you need to override gateway settings.
91106

107+
The snap requires the Docker snap. `default-provider: docker` on the OpenShell
108+
snap installs the Docker snap automatically on first use, but you can install
109+
it up front with:
110+
111+
```shell
112+
sudo snap install docker
113+
```
114+
92115
### Snap store installs
93116

94117
When installing from the Snap Store, snapd automatically connects the `home`,
@@ -123,6 +146,44 @@ to read logs and inspect system processes. The `docker` plug requires the
123146
`docker:docker-daemon` slot from the Docker snap and does not work with
124147
system-installed Docker.
125148

149+
### Connect the required interfaces
150+
151+
Strict confinement requires explicit `snap connect` for several interfaces. The
152+
installer runs these for you on Snap installs; run them by hand if you install
153+
the snap manually:
154+
155+
```shell
156+
sudo snap connect openshell:docker docker:docker-daemon
157+
sudo snap connect openshell:log-observe
158+
sudo snap connect openshell:ssh-keys
159+
sudo snap connect openshell:system-observe
160+
```
161+
162+
The Docker slot is the Docker snap's `docker-daemon` slot; OpenShell does not
163+
work with a host-installed Docker Engine. The installer is best-effort: if a
164+
connect fails (for example because the Docker snap is not yet running), the
165+
snap still installs and the installer prints a warning.
166+
167+
### Verify the gateway
168+
169+
The snap-managed gateway service is `openshell.gateway`. Inspect it with:
170+
171+
```shell
172+
snap services openshell
173+
snap logs -n 100 openshell.gateway
174+
```
175+
176+
Register the gateway with the CLI:
177+
178+
```shell
179+
openshell gateway add https://127.0.0.1:17670 --local --name openshell
180+
openshell status
181+
```
182+
183+
The gateway listens on `https://127.0.0.1:17670` and stores its state under
184+
`/var/snap/openshell/common/`. Override gateway settings by creating
185+
`/var/snap/openshell/common/gateway.toml`.
186+
126187
### Gateway service
127188

128189
The gateway runs as a snap daemon with `refresh-mode: endure`, meaning snapd
@@ -134,6 +195,21 @@ a snap refresh when you need the updated binary:
134195
sudo systemctl restart snap.openshell.gateway
135196
```
136197

198+
### When to choose Snap
199+
200+
Use Snap when `snapd` is available and no native Docker Engine is installed,
201+
and you want atomic upgrades and rollback, a single self-contained install that
202+
bundles the Docker provider, or a desktop launcher that surfaces the OpenShell
203+
terminal UI in the application menu.
204+
205+
Use DEB or RPM when `snapd` is unavailable or presents temporary limitations
206+
awaiting snapd 2.76 release: `systemd --user` integration for the gateway, or
207+
when you already run Docker Engine from a non-snap source. The installer will
208+
refuse Snap installs on hosts with native Docker — use the DEB or RPM package
209+
instead.
210+
211+
Set `OPENSHELL_INSTALL_METHOD=classic` to force the classic package on hosts
212+
that also have `snapd` available.
137213
## Kubernetes
138214

139215
Kubernetes deployments use the OpenShell Helm chart. For step-by-step installation, refer to [Kubernetes Setup](/kubernetes/setup). For chart values and packaging details, refer to the [Helm chart README](https://github.com/NVIDIA/OpenShell/blob/main/deploy/helm/openshell/README.md).

0 commit comments

Comments
 (0)