@ollamawg/cli 0.2.2 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +45 -14
- package/package.json +7 -7
package/README.md
CHANGED
|
@@ -6,7 +6,7 @@ Reach your Ollama server from your laptop and phone without exposing it to the i
|
|
|
6
6
|
|
|
7
7
|
It is a single Go binary. WireGuard runs in user space through [wireguard-go](https://git.zx2c4.com/wireguard-go) and gVisor's network stack, so the server needs no root, no kernel module and no TUN device. Computers connect with `ollamawg connect`, which needs no admin rights either. Phones use the official WireGuard app, because the keys and protocol are standard WireGuard.
|
|
8
8
|
|
|
9
|
-

|
|
10
10
|
|
|
11
11
|
<sub>Screenshot taken with simulated devices and traffic.</sub>
|
|
12
12
|
|
|
@@ -43,7 +43,7 @@ Ollama itself stays on `127.0.0.1`. Nothing outside the tunnel can talk to it.
|
|
|
43
43
|
- ask your ISP for a public IP;
|
|
44
44
|
- or relay through a small VPS.
|
|
45
45
|
|
|
46
|
-
See [Troubleshooting](https://github.com/himanshu-mamgain/ollamawg/blob/v0.
|
|
46
|
+
See [Troubleshooting](https://github.com/himanshu-mamgain/ollamawg/blob/v0.3.0/docs/getting-started.md#troubleshooting).
|
|
47
47
|
|
|
48
48
|
## Install
|
|
49
49
|
|
|
@@ -53,7 +53,7 @@ npx @ollamawg/cli version # or run it without installing
|
|
|
53
53
|
go install github.com/himanshu-mamgain/ollamawg/cmd/ollamawg@latest
|
|
54
54
|
```
|
|
55
55
|
|
|
56
|
-
Standalone binaries are attached to every [GitHub Release](https://github.com/himanshu-mamgain/ollamawg/releases). A `Dockerfile` is included; see [Running as a service](https://github.com/himanshu-mamgain/ollamawg/blob/v0.
|
|
56
|
+
Standalone binaries are attached to every [GitHub Release](https://github.com/himanshu-mamgain/ollamawg/releases). A `Dockerfile` is included; see [Running as a service](https://github.com/himanshu-mamgain/ollamawg/blob/v0.3.0/docs/deploy.md#docker).
|
|
57
57
|
|
|
58
58
|
## Quickstart
|
|
59
59
|
|
|
@@ -95,11 +95,41 @@ You can also use **Add device** in the dashboard, then **Phone**.
|
|
|
95
95
|
|
|
96
96
|
Ollama apps such as Enchanted or Reins work too: point them at `http://10.77.0.1:11434`.
|
|
97
97
|
|
|
98
|
-
<img src="https://raw.githubusercontent.com/himanshu-mamgain/ollamawg/v0.
|
|
98
|
+
<img src="https://raw.githubusercontent.com/himanshu-mamgain/ollamawg/v0.3.0/docs/images/chat.png" alt="The chat page on a phone" width="300">
|
|
99
99
|
|
|
100
100
|
<sub>Chat page on a phone, with a simulated model reply.</sub>
|
|
101
101
|
|
|
102
|
-
See [Getting started](https://github.com/himanshu-mamgain/ollamawg/blob/v0.
|
|
102
|
+
See [Getting started](https://github.com/himanshu-mamgain/ollamawg/blob/v0.3.0/docs/getting-started.md) for the full walkthrough.
|
|
103
|
+
|
|
104
|
+
## Dashboard login
|
|
105
|
+
|
|
106
|
+
The dashboard runs on the server at `http://127.0.0.1:8088`. The browser asks for a username and password.
|
|
107
|
+
|
|
108
|
+
**Username and password.** `init` creates the user `admin` with a random password, which it prints and saves in `server.yaml` under `admin.password`. To choose your own:
|
|
109
|
+
|
|
110
|
+
```sh
|
|
111
|
+
ollamawg passwd # asks for a new password twice
|
|
112
|
+
ollamawg passwd --user himanshu # also change the username
|
|
113
|
+
ollamawg init --endpoint ... --user himanshu --set-password # or choose both at setup
|
|
114
|
+
```
|
|
115
|
+
|
|
116
|
+
Passwords you choose are stored as a bcrypt hash (`admin.password_hash`), never in plain text. A running server picks up the change within 2 seconds.
|
|
117
|
+
|
|
118
|
+
**Two-factor login (2FA).** This adds a 6-digit code from an authenticator app, such as Google Authenticator, Authy, 1Password or Microsoft Authenticator.
|
|
119
|
+
|
|
120
|
+
```sh
|
|
121
|
+
ollamawg 2fa enable # shows a QR code: scan it, then type the code to confirm
|
|
122
|
+
ollamawg 2fa status
|
|
123
|
+
ollamawg 2fa disable # also the way back in if you lose your phone
|
|
124
|
+
```
|
|
125
|
+
|
|
126
|
+
You can also turn it on from the **2FA** button in the dashboard.
|
|
127
|
+
|
|
128
|
+
With 2FA on:
|
|
129
|
+
- The dashboard opens on a login form that asks for the username, password and code.
|
|
130
|
+
- Scripts and Prometheus use the API token (`admin.api_token`) as `Authorization: Bearer <token>`.
|
|
131
|
+
|
|
132
|
+
See [Dashboard and admin API](https://github.com/himanshu-mamgain/ollamawg/blob/v0.3.0/docs/dashboard.md).
|
|
103
133
|
|
|
104
134
|
## Features
|
|
105
135
|
|
|
@@ -139,6 +169,7 @@ Server
|
|
|
139
169
|
block block --device or --ip
|
|
140
170
|
unblock undo a block
|
|
141
171
|
serve run the tunnel, proxy, chat page and dashboard
|
|
172
|
+
passwd set your own dashboard username and password
|
|
142
173
|
2fa enable, disable or check two-factor dashboard login
|
|
143
174
|
|
|
144
175
|
Client
|
|
@@ -156,19 +187,19 @@ Run `ollamawg <command> -h` for a command's flags.
|
|
|
156
187
|
|
|
157
188
|
| Guide | What's in it |
|
|
158
189
|
|---|---|
|
|
159
|
-
| [Getting started](https://github.com/himanshu-mamgain/ollamawg/blob/v0.
|
|
160
|
-
| [Configuration](https://github.com/himanshu-mamgain/ollamawg/blob/v0.
|
|
161
|
-
| [Dashboard and admin API](https://github.com/himanshu-mamgain/ollamawg/blob/v0.
|
|
162
|
-
| [Security model](https://github.com/himanshu-mamgain/ollamawg/blob/v0.
|
|
163
|
-
| [Running as a service](https://github.com/himanshu-mamgain/ollamawg/blob/v0.
|
|
164
|
-
| [Go library](https://github.com/himanshu-mamgain/ollamawg/blob/v0.
|
|
190
|
+
| [Getting started](https://github.com/himanshu-mamgain/ollamawg/blob/v0.3.0/docs/getting-started.md) | Install, set up a server, add laptops and phones, connect |
|
|
191
|
+
| [Configuration](https://github.com/himanshu-mamgain/ollamawg/blob/v0.3.0/docs/configuration.md) | Every field in `server.yaml` and client configs, roles, model rules |
|
|
192
|
+
| [Dashboard and admin API](https://github.com/himanshu-mamgain/ollamawg/blob/v0.3.0/docs/dashboard.md) | The UI, two-factor login, the HTTP API behind it, Prometheus metrics |
|
|
193
|
+
| [Security model](https://github.com/himanshu-mamgain/ollamawg/blob/v0.3.0/docs/security.md) | What is protected, how, and what is not |
|
|
194
|
+
| [Running as a service](https://github.com/himanshu-mamgain/ollamawg/blob/v0.3.0/docs/deploy.md) | systemd, launchd, Windows, Docker, port forwarding |
|
|
195
|
+
| [Go library](https://github.com/himanshu-mamgain/ollamawg/blob/v0.3.0/docs/library.md) | Embedding the server and client in your own programs |
|
|
165
196
|
|
|
166
197
|
## Limitations
|
|
167
198
|
|
|
168
199
|
- **Devices need to reach one UDP port on the server.** There is no relay or NAT traversal. CGNAT connections need one of the workarounds in [Requirements](#requirements).
|
|
169
200
|
- **The dashboard has one admin account.** Put a reverse proxy with SSO in front if several people manage it.
|
|
170
201
|
- **Chat history lives in each device's browser.** It is not synced between devices or stored on the server.
|
|
171
|
-
- **No independent security audit yet.** The cryptography comes from wireguard-go and gVisor. The policy layer is small and covered by end-to-end tests. See the [Security model](https://github.com/himanshu-mamgain/ollamawg/blob/v0.
|
|
202
|
+
- **No independent security audit yet.** The cryptography comes from wireguard-go and gVisor. The policy layer is small and covered by end-to-end tests. See the [Security model](https://github.com/himanshu-mamgain/ollamawg/blob/v0.3.0/docs/security.md).
|
|
172
203
|
|
|
173
204
|
## Building from source
|
|
174
205
|
|
|
@@ -182,7 +213,7 @@ Go 1.24 or newer is required. Cross-compiling works out of the box, for example
|
|
|
182
213
|
|
|
183
214
|
## Releasing
|
|
184
215
|
|
|
185
|
-
Releases are cut from `main` by [`.github/workflows/publish.yml`](https://github.com/himanshu-mamgain/ollamawg/blob/v0.
|
|
216
|
+
Releases are cut from `main` by [`.github/workflows/publish.yml`](https://github.com/himanshu-mamgain/ollamawg/blob/v0.3.0/.github/workflows/publish.yml):
|
|
186
217
|
|
|
187
218
|
1. In a PR, bump `version` (and its `optionalDependencies`) in `npm/cli/package.json` and `Version` in `server.go`. A test fails if they differ.
|
|
188
219
|
2. Merge the PR. The workflow publishes every npm package that's missing that version, using trusted publishing with provenance, then creates the GitHub Release with binaries.
|
|
@@ -191,4 +222,4 @@ A re-run finishes a release that stopped halfway.
|
|
|
191
222
|
|
|
192
223
|
## License
|
|
193
224
|
|
|
194
|
-
[MIT](https://github.com/himanshu-mamgain/ollamawg/blob/v0.
|
|
225
|
+
[MIT](https://github.com/himanshu-mamgain/ollamawg/blob/v0.3.0/LICENSE)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ollamawg/cli",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.3.0",
|
|
4
4
|
"description": "Reach your Ollama server from anywhere through a user-space WireGuard tunnel, with per-device access control and a dashboard.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ollama",
|
|
@@ -28,11 +28,11 @@
|
|
|
28
28
|
"node": ">=16"
|
|
29
29
|
},
|
|
30
30
|
"optionalDependencies": {
|
|
31
|
-
"@ollamawg/darwin-arm64": "0.
|
|
32
|
-
"@ollamawg/darwin-x64": "0.
|
|
33
|
-
"@ollamawg/freebsd-x64": "0.
|
|
34
|
-
"@ollamawg/linux-arm64": "0.
|
|
35
|
-
"@ollamawg/linux-x64": "0.
|
|
36
|
-
"@ollamawg/win32-x64": "0.
|
|
31
|
+
"@ollamawg/darwin-arm64": "0.3.0",
|
|
32
|
+
"@ollamawg/darwin-x64": "0.3.0",
|
|
33
|
+
"@ollamawg/freebsd-x64": "0.3.0",
|
|
34
|
+
"@ollamawg/linux-arm64": "0.3.0",
|
|
35
|
+
"@ollamawg/linux-x64": "0.3.0",
|
|
36
|
+
"@ollamawg/win32-x64": "0.3.0"
|
|
37
37
|
}
|
|
38
38
|
}
|