Skip to content

Commit a95c5fd

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

1 file changed

Lines changed: 86 additions & 1 deletion

File tree

‎docs/about/installation.mdx‎

Lines changed: 86 additions & 1 deletion
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.
@@ -75,6 +85,81 @@ To keep the user service running after logout, enable linger:
7585
sudo loginctl enable-linger $USER
7686
```
7787

88+
## Snap
89+
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:
96+
97+
```shell
98+
sudo snap install openshell
99+
```
100+
101+
The snap requires the Docker snap. `default-provider: docker` on the OpenShell
102+
snap installs the Docker snap automatically on first use, but you can install
103+
it up front with:
104+
105+
```shell
106+
sudo snap install docker
107+
```
108+
109+
### Connect the required interfaces
110+
111+
Strict confinement requires explicit `snap connect` for several interfaces. The
112+
installer runs these for you on Snap installs; run them by hand if you install
113+
the snap manually:
114+
115+
```shell
116+
sudo snap connect openshell:docker docker:docker-daemon
117+
sudo snap connect openshell:log-observe
118+
sudo snap connect openshell:ssh-keys
119+
sudo snap connect openshell:system-observe
120+
```
121+
122+
The Docker slot is the Docker snap's `docker-daemon` slot; OpenShell does not
123+
work with a host-installed Docker Engine. The installer is best-effort: if a
124+
connect fails (for example because the Docker snap is not yet running), the
125+
snap still installs and the installer prints a warning.
126+
127+
### Verify the gateway
128+
129+
The snap-managed gateway service is `openshell.gateway`. Inspect it with:
130+
131+
```shell
132+
snap services openshell
133+
snap logs -n 100 openshell.gateway
134+
```
135+
136+
Register the gateway with the CLI:
137+
138+
```shell
139+
openshell gateway add https://127.0.0.1:17670 --local --name openshell
140+
openshell status
141+
```
142+
143+
The gateway listens on `https://127.0.0.1:17670` and stores its state under
144+
`/var/snap/openshell/common/`. Override gateway settings by creating
145+
`/var/snap/openshell/common/gateway.toml`.
146+
147+
### When to choose Snap
148+
149+
Use Snap when `snapd` is available and no native Docker Engine is installed,
150+
and you want atomic upgrades and rollback, a single self-contained install that
151+
bundles the Docker provider, or a desktop launcher that surfaces the OpenShell
152+
terminal UI in the application menu.
153+
154+
Use DEB or RPM when `snapd` is unavailable or presents temporary limitations
155+
awaiting snapd 2.76 release: `systemd --user` integration for the gateway, or
156+
when you already run Docker Engine from a non-snap source. The installer will
157+
refuse Snap installs on hosts with native Docker — use the DEB or RPM package
158+
instead.
159+
160+
Set `OPENSHELL_INSTALL_METHOD=classic` to force the classic package on hosts
161+
that also have `snapd` available.
162+
78163
## Kubernetes
79164

80165
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)