@lamalibre/create-lamaste 4.0.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/LICENSE.md +118 -0
- package/README.md +114 -0
- package/bin/create-lamaste.js +15 -0
- package/package.json +54 -0
- package/scripts/bundle-vendor.js +110 -0
- package/scripts/lamaste-cert-info +62 -0
- package/scripts/lamaste-certbot +96 -0
- package/scripts/lamaste-priv +693 -0
- package/src/index.js +646 -0
- package/src/lib/accounts.js +86 -0
- package/src/lib/binaries.js +137 -0
- package/src/lib/cert-help-page.js +160 -0
- package/src/lib/env.js +132 -0
- package/src/lib/http-redirect.js +38 -0
- package/src/lib/ownership.js +231 -0
- package/src/lib/relay-services.js +103 -0
- package/src/lib/secrets.js +19 -0
- package/src/lib/service-config.js +311 -0
- package/src/lib/summary.js +131 -0
- package/src/lib/wrappers.js +63 -0
- package/src/tasks/gatekeeper.js +233 -0
- package/src/tasks/harden.js +293 -0
- package/src/tasks/mtls.js +193 -0
- package/src/tasks/nginx.js +265 -0
- package/src/tasks/node.js +110 -0
- package/src/tasks/panel.js +408 -0
- package/src/tasks/redeploy.js +438 -0
- package/vendor/docs/00-introduction/how-it-works.md +447 -0
- package/vendor/docs/00-introduction/quickstart.md +472 -0
- package/vendor/docs/00-introduction/what-is-lamaste.md +112 -0
- package/vendor/docs/01-concepts/authentication.md +464 -0
- package/vendor/docs/01-concepts/authorization.md +242 -0
- package/vendor/docs/01-concepts/certificates.md +452 -0
- package/vendor/docs/01-concepts/dns-and-domains.md +343 -0
- package/vendor/docs/01-concepts/mtls.md +490 -0
- package/vendor/docs/01-concepts/nginx-reverse-proxy.md +540 -0
- package/vendor/docs/01-concepts/security-model.md +600 -0
- package/vendor/docs/01-concepts/tickets.md +414 -0
- package/vendor/docs/01-concepts/tunneling.md +367 -0
- package/vendor/docs/02-guides/agent-setup.md +194 -0
- package/vendor/docs/02-guides/certificate-management.md +341 -0
- package/vendor/docs/02-guides/cloud-provisioning.md +406 -0
- package/vendor/docs/02-guides/desktop-app-setup.md +226 -0
- package/vendor/docs/02-guides/disaster-recovery.md +464 -0
- package/vendor/docs/02-guides/first-tunnel.md +230 -0
- package/vendor/docs/02-guides/installation.md +393 -0
- package/vendor/docs/02-guides/managing-users.md +255 -0
- package/vendor/docs/02-guides/onboarding.md +244 -0
- package/vendor/docs/02-guides/standalone-plugin-with-tickets.md +375 -0
- package/vendor/docs/02-guides/static-sites.md +364 -0
- package/vendor/docs/03-architecture/e2e-three-vm-sequences.md +457 -0
- package/vendor/docs/03-architecture/installer-flow.md +151 -0
- package/vendor/docs/03-architecture/installer.md +445 -0
- package/vendor/docs/03-architecture/management-flow.md +288 -0
- package/vendor/docs/03-architecture/nginx-configuration.md +830 -0
- package/vendor/docs/03-architecture/onboarding-flow.md +164 -0
- package/vendor/docs/03-architecture/overview.md +541 -0
- package/vendor/docs/03-architecture/panel-client.md +416 -0
- package/vendor/docs/03-architecture/panel-server.md +695 -0
- package/vendor/docs/03-architecture/state-management.md +529 -0
- package/vendor/docs/03-architecture/system-overview.md +167 -0
- package/vendor/docs/04-api-reference/certificates.md +1141 -0
- package/vendor/docs/04-api-reference/gatekeeper.md +592 -0
- package/vendor/docs/04-api-reference/onboarding.md +473 -0
- package/vendor/docs/04-api-reference/overview.md +404 -0
- package/vendor/docs/04-api-reference/services.md +267 -0
- package/vendor/docs/04-api-reference/settings.md +343 -0
- package/vendor/docs/04-api-reference/sites.md +716 -0
- package/vendor/docs/04-api-reference/system.md +268 -0
- package/vendor/docs/04-api-reference/tickets.md +618 -0
- package/vendor/docs/04-api-reference/tunnels.md +417 -0
- package/vendor/docs/04-api-reference/users.md +333 -0
- package/vendor/docs/05-operations/backup-and-restore.md +342 -0
- package/vendor/docs/05-operations/monitoring.md +285 -0
- package/vendor/docs/05-operations/uninstalling.md +344 -0
- package/vendor/docs/05-operations/upgrades.md +270 -0
- package/vendor/docs/06-reference/config-files.md +1080 -0
- package/vendor/docs/06-reference/glossary.md +528 -0
- package/vendor/docs/06-reference/installer-flags.md +260 -0
- package/vendor/docs/06-reference/ports-and-services.md +244 -0
- package/vendor/docs/06-reference/troubleshooting.md +665 -0
- package/vendor/docs/_index.json +233 -0
- package/vendor/docs/gatekeeper-design.md +953 -0
- package/vendor/docs/package.json +15 -0
- package/vendor/docs/todo/lib-cli-desktop-refactor.md +641 -0
- package/vendor/gatekeeper/dist/boot.d.ts +1 -0
- package/vendor/gatekeeper/dist/boot.d.ts.map +1 -0
- package/vendor/gatekeeper/dist/boot.js +17 -0
- package/vendor/gatekeeper/dist/boot.js.map +1 -0
- package/vendor/gatekeeper/dist/cli/commands/access.d.ts +2 -0
- package/vendor/gatekeeper/dist/cli/commands/access.d.ts.map +1 -0
- package/vendor/gatekeeper/dist/cli/commands/access.js +33 -0
- package/vendor/gatekeeper/dist/cli/commands/access.js.map +1 -0
- package/vendor/gatekeeper/dist/cli/commands/grants.d.ts +2 -0
- package/vendor/gatekeeper/dist/cli/commands/grants.d.ts.map +1 -0
- package/vendor/gatekeeper/dist/cli/commands/grants.js +110 -0
- package/vendor/gatekeeper/dist/cli/commands/grants.js.map +1 -0
- package/vendor/gatekeeper/dist/cli/commands/groups.d.ts +2 -0
- package/vendor/gatekeeper/dist/cli/commands/groups.d.ts.map +1 -0
- package/vendor/gatekeeper/dist/cli/commands/groups.js +98 -0
- package/vendor/gatekeeper/dist/cli/commands/groups.js.map +1 -0
- package/vendor/gatekeeper/dist/cli/index.d.ts +3 -0
- package/vendor/gatekeeper/dist/cli/index.d.ts.map +1 -0
- package/vendor/gatekeeper/dist/cli/index.js +45 -0
- package/vendor/gatekeeper/dist/cli/index.js.map +1 -0
- package/vendor/gatekeeper/dist/index.d.ts +9 -0
- package/vendor/gatekeeper/dist/index.d.ts.map +1 -0
- package/vendor/gatekeeper/dist/index.js +13 -0
- package/vendor/gatekeeper/dist/index.js.map +1 -0
- package/vendor/gatekeeper/dist/lib/authz.d.ts +16 -0
- package/vendor/gatekeeper/dist/lib/authz.d.ts.map +1 -0
- package/vendor/gatekeeper/dist/lib/authz.js +42 -0
- package/vendor/gatekeeper/dist/lib/authz.js.map +1 -0
- package/vendor/gatekeeper/dist/lib/cache-bust.d.ts +15 -0
- package/vendor/gatekeeper/dist/lib/cache-bust.d.ts.map +1 -0
- package/vendor/gatekeeper/dist/lib/cache-bust.js +19 -0
- package/vendor/gatekeeper/dist/lib/cache-bust.js.map +1 -0
- package/vendor/gatekeeper/dist/lib/constants.d.ts +82 -0
- package/vendor/gatekeeper/dist/lib/constants.d.ts.map +1 -0
- package/vendor/gatekeeper/dist/lib/constants.js +79 -0
- package/vendor/gatekeeper/dist/lib/constants.js.map +1 -0
- package/vendor/gatekeeper/dist/lib/grants.d.ts +32 -0
- package/vendor/gatekeeper/dist/lib/grants.d.ts.map +1 -0
- package/vendor/gatekeeper/dist/lib/grants.js +314 -0
- package/vendor/gatekeeper/dist/lib/grants.js.map +1 -0
- package/vendor/gatekeeper/dist/lib/groups.d.ts +10 -0
- package/vendor/gatekeeper/dist/lib/groups.d.ts.map +1 -0
- package/vendor/gatekeeper/dist/lib/groups.js +247 -0
- package/vendor/gatekeeper/dist/lib/groups.js.map +1 -0
- package/vendor/gatekeeper/dist/lib/migration.d.ts +17 -0
- package/vendor/gatekeeper/dist/lib/migration.d.ts.map +1 -0
- package/vendor/gatekeeper/dist/lib/migration.js +79 -0
- package/vendor/gatekeeper/dist/lib/migration.js.map +1 -0
- package/vendor/gatekeeper/dist/lib/migrations/gatekeeper/0001_groups.sql +7 -0
- package/vendor/gatekeeper/dist/lib/migrations/gatekeeper/0002_access_grants.sql +14 -0
- package/vendor/gatekeeper/dist/lib/migrations/gatekeeper/0003_access_request_log.sql +9 -0
- package/vendor/gatekeeper/dist/lib/migrations/migrations/gatekeeper/0001_groups.sql +7 -0
- package/vendor/gatekeeper/dist/lib/migrations/migrations/gatekeeper/0002_access_grants.sql +14 -0
- package/vendor/gatekeeper/dist/lib/migrations/migrations/gatekeeper/0003_access_request_log.sql +9 -0
- package/vendor/gatekeeper/dist/lib/state-db.d.ts +16 -0
- package/vendor/gatekeeper/dist/lib/state-db.d.ts.map +1 -0
- package/vendor/gatekeeper/dist/lib/state-db.js +154 -0
- package/vendor/gatekeeper/dist/lib/state-db.js.map +1 -0
- package/vendor/gatekeeper/dist/lib/templates.d.ts +21 -0
- package/vendor/gatekeeper/dist/lib/templates.d.ts.map +1 -0
- package/vendor/gatekeeper/dist/lib/templates.js +151 -0
- package/vendor/gatekeeper/dist/lib/templates.js.map +1 -0
- package/vendor/gatekeeper/dist/lib/types.d.ts +178 -0
- package/vendor/gatekeeper/dist/lib/types.d.ts.map +1 -0
- package/vendor/gatekeeper/dist/lib/types.js +2 -0
- package/vendor/gatekeeper/dist/lib/types.js.map +1 -0
- package/vendor/gatekeeper/dist/server/index.d.ts +15 -0
- package/vendor/gatekeeper/dist/server/index.d.ts.map +1 -0
- package/vendor/gatekeeper/dist/server/index.js +251 -0
- package/vendor/gatekeeper/dist/server/index.js.map +1 -0
- package/vendor/gatekeeper/dist/server/routes/access-request.d.ts +7 -0
- package/vendor/gatekeeper/dist/server/routes/access-request.d.ts.map +1 -0
- package/vendor/gatekeeper/dist/server/routes/access-request.js +17 -0
- package/vendor/gatekeeper/dist/server/routes/access-request.js.map +1 -0
- package/vendor/gatekeeper/dist/server/routes/authz.d.ts +3 -0
- package/vendor/gatekeeper/dist/server/routes/authz.d.ts.map +1 -0
- package/vendor/gatekeeper/dist/server/routes/authz.js +279 -0
- package/vendor/gatekeeper/dist/server/routes/authz.js.map +1 -0
- package/vendor/gatekeeper/dist/server/routes/diagnostic.d.ts +13 -0
- package/vendor/gatekeeper/dist/server/routes/diagnostic.d.ts.map +1 -0
- package/vendor/gatekeeper/dist/server/routes/diagnostic.js +249 -0
- package/vendor/gatekeeper/dist/server/routes/diagnostic.js.map +1 -0
- package/vendor/gatekeeper/dist/server/routes/grants.d.ts +3 -0
- package/vendor/gatekeeper/dist/server/routes/grants.d.ts.map +1 -0
- package/vendor/gatekeeper/dist/server/routes/grants.js +112 -0
- package/vendor/gatekeeper/dist/server/routes/grants.js.map +1 -0
- package/vendor/gatekeeper/dist/server/routes/groups.d.ts +3 -0
- package/vendor/gatekeeper/dist/server/routes/groups.d.ts.map +1 -0
- package/vendor/gatekeeper/dist/server/routes/groups.js +139 -0
- package/vendor/gatekeeper/dist/server/routes/groups.js.map +1 -0
- package/vendor/gatekeeper/package.json +49 -0
- package/vendor/server/bin/lamaste-server.js +204 -0
- package/vendor/server/package.json +31 -0
- package/vendor/server/src/commands/certs.js +224 -0
- package/vendor/server/src/commands/chisel.js +132 -0
- package/vendor/server/src/commands/logs.js +49 -0
- package/vendor/server/src/commands/plugins.js +321 -0
- package/vendor/server/src/commands/reset-admin.js +478 -0
- package/vendor/server/src/commands/restart.js +94 -0
- package/vendor/server/src/commands/sites.js +257 -0
- package/vendor/server/src/commands/status.js +158 -0
- package/vendor/server/src/commands/tunnels.js +365 -0
- package/vendor/server/src/commands/uninstall.js +326 -0
- package/vendor/server/src/config.js +38 -0
- package/vendor/server/src/exec.js +26 -0
- package/vendor/server/src/logger.js +39 -0
- package/vendor/server/src/ndjson.js +56 -0
- package/vendor/server/src/panel-api.js +85 -0
- package/vendor/server/src/state.js +45 -0
- package/vendor/server-ui/dist/assets/index-B0nWuUyL.js +257 -0
- package/vendor/server-ui/dist/assets/index-BqWWFlTU.css +1 -0
- package/vendor/server-ui/dist/index.html +13 -0
- package/vendor/serverd/package.json +44 -0
- package/vendor/serverd/src/boot.js +13 -0
- package/vendor/serverd/src/index.js +191 -0
- package/vendor/serverd/src/lib/app-error.js +14 -0
- package/vendor/serverd/src/lib/authelia.js +85 -0
- package/vendor/serverd/src/lib/certbot.js +74 -0
- package/vendor/serverd/src/lib/chisel-args.js +6 -0
- package/vendor/serverd/src/lib/chisel-reconcile.js +232 -0
- package/vendor/serverd/src/lib/chisel-runtime.js +46 -0
- package/vendor/serverd/src/lib/chisel-users.js +109 -0
- package/vendor/serverd/src/lib/chisel.js +81 -0
- package/vendor/serverd/src/lib/config.js +190 -0
- package/vendor/serverd/src/lib/constants.js +8 -0
- package/vendor/serverd/src/lib/csr-signing.js +331 -0
- package/vendor/serverd/src/lib/enrollment.js +302 -0
- package/vendor/serverd/src/lib/files.js +19 -0
- package/vendor/serverd/src/lib/gatekeeper-client.js +135 -0
- package/vendor/serverd/src/lib/invite-page.js +281 -0
- package/vendor/serverd/src/lib/ip-utils.js +79 -0
- package/vendor/serverd/src/lib/migrations/state/0001_enrollment_tokens.sql +17 -0
- package/vendor/serverd/src/lib/migrations/state/0002_tickets.sql +70 -0
- package/vendor/serverd/src/lib/migrations/state/0003_plugins.sql +15 -0
- package/vendor/serverd/src/lib/migrations/state/0004_agents.sql +19 -0
- package/vendor/serverd/src/lib/mtls.js +795 -0
- package/vendor/serverd/src/lib/nginx.js +1090 -0
- package/vendor/serverd/src/lib/pki-paths.js +41 -0
- package/vendor/serverd/src/lib/pki-sign.js +103 -0
- package/vendor/serverd/src/lib/plugins.js +538 -0
- package/vendor/serverd/src/lib/push-install.js +390 -0
- package/vendor/serverd/src/lib/revocation.js +112 -0
- package/vendor/serverd/src/lib/services.js +131 -0
- package/vendor/serverd/src/lib/session.js +151 -0
- package/vendor/serverd/src/lib/state-db.js +130 -0
- package/vendor/serverd/src/lib/state.js +140 -0
- package/vendor/serverd/src/lib/storage.js +63 -0
- package/vendor/serverd/src/lib/system-stats.js +58 -0
- package/vendor/serverd/src/lib/tickets.js +1556 -0
- package/vendor/serverd/src/lib/totp.js +76 -0
- package/vendor/serverd/src/lib/tunnel-deps.js +41 -0
- package/vendor/serverd/src/lib/user-access-session.js +142 -0
- package/vendor/serverd/src/lib/user-access.js +52 -0
- package/vendor/serverd/src/middleware/errors.js +63 -0
- package/vendor/serverd/src/middleware/mtls.js +120 -0
- package/vendor/serverd/src/middleware/onboarding-guard.js +30 -0
- package/vendor/serverd/src/middleware/role-guard.js +58 -0
- package/vendor/serverd/src/middleware/twofa-session.js +65 -0
- package/vendor/serverd/src/middleware/user-access-session.js +52 -0
- package/vendor/serverd/src/routes/enrollment.js +120 -0
- package/vendor/serverd/src/routes/health.js +22 -0
- package/vendor/serverd/src/routes/invite.js +163 -0
- package/vendor/serverd/src/routes/management/agents.js +182 -0
- package/vendor/serverd/src/routes/management/certs.js +911 -0
- package/vendor/serverd/src/routes/management/gatekeeper-proxy.js +160 -0
- package/vendor/serverd/src/routes/management/identity.js +107 -0
- package/vendor/serverd/src/routes/management/invitations.js +166 -0
- package/vendor/serverd/src/routes/management/logs.js +218 -0
- package/vendor/serverd/src/routes/management/plugins.js +560 -0
- package/vendor/serverd/src/routes/management/services.js +63 -0
- package/vendor/serverd/src/routes/management/settings.js +325 -0
- package/vendor/serverd/src/routes/management/sites.js +522 -0
- package/vendor/serverd/src/routes/management/storage.js +192 -0
- package/vendor/serverd/src/routes/management/system.js +201 -0
- package/vendor/serverd/src/routes/management/tickets.js +457 -0
- package/vendor/serverd/src/routes/management/tunnels.js +709 -0
- package/vendor/serverd/src/routes/management/users.js +377 -0
- package/vendor/serverd/src/routes/management.js +36 -0
- package/vendor/serverd/src/routes/onboarding/dns.js +101 -0
- package/vendor/serverd/src/routes/onboarding/domain.js +42 -0
- package/vendor/serverd/src/routes/onboarding/index.js +18 -0
- package/vendor/serverd/src/routes/onboarding/provision.js +327 -0
- package/vendor/serverd/src/routes/onboarding/status.js +12 -0
- package/vendor/serverd/src/routes/plugin-router.js +79 -0
- package/vendor/serverd/src/routes/user-access.js +389 -0
|
@@ -0,0 +1,472 @@
|
|
|
1
|
+
# Quick Start
|
|
2
|
+
|
|
3
|
+
> Go from zero to your first publicly accessible tunnel in about 10 minutes, using a $4 DigitalOcean droplet and your Mac or Linux machine.
|
|
4
|
+
|
|
5
|
+
## In Plain English
|
|
6
|
+
|
|
7
|
+
This guide walks you through the entire process of setting up Lamaste. By the end, you will have a web app running on your machine that anyone on the internet can access through your own domain, protected by two-factor authentication.
|
|
8
|
+
|
|
9
|
+
Think of it as three steps: rent a storefront (create a droplet), set up the store (run the installer), and open for business (create a tunnel). The whole process takes about as long as making a cup of coffee.
|
|
10
|
+
|
|
11
|
+
## For Users
|
|
12
|
+
|
|
13
|
+
> **Alternative:** If you prefer a graphical experience, the [Desktop App](../02-guides/desktop-app-setup.md) can provision a DigitalOcean droplet and set up everything automatically — no SSH required. See the [Cloud Provisioning guide](../02-guides/cloud-provisioning.md) for a step-by-step walkthrough. The guide below covers the manual SSH approach.
|
|
14
|
+
|
|
15
|
+
### Prerequisites
|
|
16
|
+
|
|
17
|
+
Before you start, make sure you have:
|
|
18
|
+
|
|
19
|
+
| Requirement | Details |
|
|
20
|
+
| -------------------------- | -------------------------------------------------------------------------------------------------- |
|
|
21
|
+
| **DigitalOcean account** | Any cloud provider works, but this guide uses DigitalOcean. You need a fresh Ubuntu 24.04 droplet. |
|
|
22
|
+
| **Domain name** | A domain you control (e.g., `example.com`). You need access to its DNS settings. |
|
|
23
|
+
| **Mac (or Linux machine)** | The computer running the web apps you want to expose. Must have outbound internet access. |
|
|
24
|
+
| **SSH key** | An SSH key pair for accessing the droplet. DigitalOcean can generate one during droplet creation. |
|
|
25
|
+
| **A local web app** | Something listening on a port — a dev server, a blog engine, any HTTP service. |
|
|
26
|
+
|
|
27
|
+
**Cost:** $4/month for the smallest DigitalOcean droplet (512MB RAM, 1 vCPU). That is all you need.
|
|
28
|
+
|
|
29
|
+
---
|
|
30
|
+
|
|
31
|
+
### Step 1: Create a Droplet
|
|
32
|
+
|
|
33
|
+
Log in to DigitalOcean and create a new droplet:
|
|
34
|
+
|
|
35
|
+
| Setting | Value |
|
|
36
|
+
| -------------- | ------------------------------------------ |
|
|
37
|
+
| Image | Ubuntu 24.04 (LTS) |
|
|
38
|
+
| Plan | Basic, $4/mo (512MB RAM, 1 vCPU, 10GB SSD) |
|
|
39
|
+
| Region | Closest to your users |
|
|
40
|
+
| Authentication | SSH key (not password) |
|
|
41
|
+
|
|
42
|
+
Wait for the droplet to boot. Note its public IP address (e.g., `203.0.113.42`).
|
|
43
|
+
|
|
44
|
+
```
|
|
45
|
+
Droplet created: 203.0.113.42
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
---
|
|
49
|
+
|
|
50
|
+
### Step 2: Run the Installer
|
|
51
|
+
|
|
52
|
+
SSH into the droplet and run the Lamaste installer:
|
|
53
|
+
|
|
54
|
+
```bash
|
|
55
|
+
ssh root@203.0.113.42
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
Once connected:
|
|
59
|
+
|
|
60
|
+
```bash
|
|
61
|
+
apt install -y npm
|
|
62
|
+
npx @lamalibre/create-lamaste@4.0.0
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
The installer displays a confirmation banner showing what it will do:
|
|
66
|
+
|
|
67
|
+
```
|
|
68
|
+
┌─────────────────────────────────────────────────────────────┐
|
|
69
|
+
│ Lamaste Installer │
|
|
70
|
+
├─────────────────────────────────────────────────────────────┤
|
|
71
|
+
│ │
|
|
72
|
+
│ This will install Lamaste on this machine. │
|
|
73
|
+
│ │
|
|
74
|
+
│ The following changes will be made: │
|
|
75
|
+
│ │
|
|
76
|
+
│ * Reset UFW firewall (allow ports 22, 443, 9292 only) │
|
|
77
|
+
│ * Harden SSH (disable password authentication) │
|
|
78
|
+
│ * Install fail2ban, Node.js 20, nginx, certbot │
|
|
79
|
+
│ * Generate mTLS certificates for browser access │
|
|
80
|
+
│ * Create lamaste user and systemd service │
|
|
81
|
+
│ * Deploy panel to /opt/lamalibre/lamaste/ │
|
|
82
|
+
│ │
|
|
83
|
+
│ Designed for a fresh Ubuntu 24.04 droplet. │
|
|
84
|
+
│ │
|
|
85
|
+
└─────────────────────────────────────────────────────────────┘
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
Press Enter to continue. The installer runs for 2-3 minutes:
|
|
89
|
+
|
|
90
|
+
```
|
|
91
|
+
✔ Checking environment
|
|
92
|
+
✔ Verifying root access
|
|
93
|
+
✔ Detecting operating system → Ubuntu 24.04.1 LTS
|
|
94
|
+
✔ Detecting IP address → 203.0.113.42
|
|
95
|
+
✔ Hardening operating system
|
|
96
|
+
✔ Creating swap file
|
|
97
|
+
✔ Configuring UFW firewall
|
|
98
|
+
✔ Installing and configuring fail2ban
|
|
99
|
+
✔ Hardening SSH configuration
|
|
100
|
+
✔ Installing system dependencies
|
|
101
|
+
✔ Installing Node.js 20
|
|
102
|
+
✔ Generating mTLS certificates
|
|
103
|
+
✔ Creating PKI directory
|
|
104
|
+
✔ Generating CA private key and certificate
|
|
105
|
+
✔ Generating client key and CSR
|
|
106
|
+
✔ Signing client certificate with CA
|
|
107
|
+
✔ Creating PKCS12 bundle
|
|
108
|
+
✔ Configuring nginx
|
|
109
|
+
✔ Deploying Lamaste panel
|
|
110
|
+
✔ Installation complete
|
|
111
|
+
```
|
|
112
|
+
|
|
113
|
+
At the end, a summary box appears with everything you need:
|
|
114
|
+
|
|
115
|
+
```
|
|
116
|
+
╔════════════════════════════════════════════════════════════════╗
|
|
117
|
+
║ ║
|
|
118
|
+
║ Lamaste installed successfully! ║
|
|
119
|
+
║ ║
|
|
120
|
+
╠════════════════════════════════════════════════════════════════╣
|
|
121
|
+
║ ║
|
|
122
|
+
║ 1. Download your client certificate: ║
|
|
123
|
+
║ ║
|
|
124
|
+
║ scp root@203.0.113.42:/etc/lamalibre/lamaste/pki/client.p12 . ║
|
|
125
|
+
║ ║
|
|
126
|
+
║ 2. Import client.p12 into your browser ║
|
|
127
|
+
║ ║
|
|
128
|
+
║ 3. Certificate password: ║
|
|
129
|
+
║ ║
|
|
130
|
+
║ a1b2c3d4e5f6g7h8i9j0k1l2 ║
|
|
131
|
+
║ ║
|
|
132
|
+
║ 4. Open the Lamaste panel: ║
|
|
133
|
+
║ ║
|
|
134
|
+
║ https://203.0.113.42:9292 ║
|
|
135
|
+
║ ║
|
|
136
|
+
║ You can now disconnect from SSH. ║
|
|
137
|
+
║ ║
|
|
138
|
+
╚════════════════════════════════════════════════════════════════╝
|
|
139
|
+
```
|
|
140
|
+
|
|
141
|
+
---
|
|
142
|
+
|
|
143
|
+
### Step 3: Download the Client Certificate
|
|
144
|
+
|
|
145
|
+
On your local machine (not the droplet), open a new terminal and run the SCP command from the summary:
|
|
146
|
+
|
|
147
|
+
```bash
|
|
148
|
+
scp root@203.0.113.42:/etc/lamalibre/lamaste/pki/client.p12 .
|
|
149
|
+
```
|
|
150
|
+
|
|
151
|
+
This downloads `client.p12` to your current directory. This file is your admin credential — it proves to the panel that you are the owner.
|
|
152
|
+
|
|
153
|
+
---
|
|
154
|
+
|
|
155
|
+
### Step 4: Import the Certificate
|
|
156
|
+
|
|
157
|
+
The import process varies by operating system:
|
|
158
|
+
|
|
159
|
+
**macOS:**
|
|
160
|
+
|
|
161
|
+
1. Double-click `client.p12`
|
|
162
|
+
2. Keychain Access opens. Select the **System** keychain (not "login")
|
|
163
|
+
3. Enter the certificate password from the installer summary
|
|
164
|
+
4. Find the certificate in the System keychain, double-click it
|
|
165
|
+
5. Expand **Trust**, set to **Always Trust**
|
|
166
|
+
6. Close and enter your macOS password to confirm
|
|
167
|
+
|
|
168
|
+
If you see an error about "Local Items" — ignore it. The System keychain import is what matters.
|
|
169
|
+
|
|
170
|
+
**Linux (Chrome/Chromium):**
|
|
171
|
+
|
|
172
|
+
1. Open Chrome Settings, then Privacy and Security, then Security
|
|
173
|
+
2. Click Manage certificates, then Import
|
|
174
|
+
3. Select `client.p12` and enter the password
|
|
175
|
+
|
|
176
|
+
**Windows:**
|
|
177
|
+
|
|
178
|
+
1. Double-click `client.p12`
|
|
179
|
+
2. The Certificate Import Wizard opens
|
|
180
|
+
3. Enter the password and follow the prompts
|
|
181
|
+
|
|
182
|
+
After importing, **restart your browser** to ensure it picks up the new certificate.
|
|
183
|
+
|
|
184
|
+
---
|
|
185
|
+
|
|
186
|
+
### Step 5: Open the Admin Panel
|
|
187
|
+
|
|
188
|
+
Navigate to the URL from the installer summary:
|
|
189
|
+
|
|
190
|
+
```
|
|
191
|
+
https://203.0.113.42:9292
|
|
192
|
+
```
|
|
193
|
+
|
|
194
|
+
Your browser will show two prompts:
|
|
195
|
+
|
|
196
|
+
1. **Self-signed certificate warning**: Click "Advanced" then "Proceed" (this is expected — the panel uses a self-signed TLS certificate for the IP-based URL)
|
|
197
|
+
2. **Client certificate selection**: Your browser asks which certificate to use. Select the Lamaste certificate you just imported.
|
|
198
|
+
|
|
199
|
+
You are now in the admin panel. The onboarding wizard starts automatically.
|
|
200
|
+
|
|
201
|
+
---
|
|
202
|
+
|
|
203
|
+
### Step 6: Complete Onboarding
|
|
204
|
+
|
|
205
|
+
The onboarding wizard has three steps:
|
|
206
|
+
|
|
207
|
+
**Step 6a: Domain and Email**
|
|
208
|
+
|
|
209
|
+
Enter your domain name and email address:
|
|
210
|
+
|
|
211
|
+
```
|
|
212
|
+
Domain: example.com
|
|
213
|
+
Email: admin@example.com
|
|
214
|
+
```
|
|
215
|
+
|
|
216
|
+
The email is used for Let's Encrypt certificate notifications. The domain is where your tunneled apps will be accessible.
|
|
217
|
+
|
|
218
|
+
**Step 6b: DNS Verification**
|
|
219
|
+
|
|
220
|
+
The wizard shows the DNS records you need to create:
|
|
221
|
+
|
|
222
|
+
```
|
|
223
|
+
Type Name Value
|
|
224
|
+
A example.com 203.0.113.42
|
|
225
|
+
A *.example.com 203.0.113.42
|
|
226
|
+
```
|
|
227
|
+
|
|
228
|
+
Go to your domain registrar's DNS settings and create these records. The wildcard (`*`) record allows you to create tunnels like `app.example.com`, `blog.example.com`, etc., without adding DNS records for each one.
|
|
229
|
+
|
|
230
|
+
Click "Verify DNS" in the wizard. It checks that the records resolve correctly. DNS propagation can take a few minutes — the wizard retries automatically.
|
|
231
|
+
|
|
232
|
+
**Step 6c: Provisioning**
|
|
233
|
+
|
|
234
|
+
Click "Provision" and watch the progress. The wizard:
|
|
235
|
+
|
|
236
|
+
1. Downloads and installs Chisel (tunnel server)
|
|
237
|
+
2. Downloads and installs Authelia (2FA authentication)
|
|
238
|
+
3. Creates the first admin user with TOTP 2FA
|
|
239
|
+
4. Issues a Let's Encrypt TLS certificate for your domain
|
|
240
|
+
5. Writes nginx vhost configurations
|
|
241
|
+
6. Starts all services
|
|
242
|
+
|
|
243
|
+
This takes 1-2 minutes. When it finishes, onboarding is complete. The page shows your first user's TOTP QR code — scan it with Google Authenticator, Authy, or any TOTP app.
|
|
244
|
+
|
|
245
|
+
---
|
|
246
|
+
|
|
247
|
+
### Step 7: Enroll Your Machine as an Agent
|
|
248
|
+
|
|
249
|
+
Every tunnel is carried by one **agent** — the machine that runs the app. Enroll that machine first.
|
|
250
|
+
|
|
251
|
+
**Option A — Desktop App (recommended):**
|
|
252
|
+
|
|
253
|
+
Install the Lamaste Desktop app, which provides a GUI with automatic service discovery and one-click tunnel creation:
|
|
254
|
+
|
|
255
|
+
```bash
|
|
256
|
+
npx @lamalibre/create-lamaste-desktop@4.0.0
|
|
257
|
+
```
|
|
258
|
+
|
|
259
|
+
The app auto-detects local services (Ollama, ComfyUI, PostgreSQL, Docker containers, etc.) and lets you expose them with one click. See the [Desktop App Setup](../02-guides/desktop-app-setup.md) guide for details.
|
|
260
|
+
|
|
261
|
+
**Option B — Agent CLI (macOS, Linux servers and VMs):**
|
|
262
|
+
|
|
263
|
+
In the panel, go to **Certificates → Enrollment Token** and create a token for a label such as `laptop`. Then, on the machine that runs your app, install the agent globally and run setup:
|
|
264
|
+
|
|
265
|
+
```bash
|
|
266
|
+
npm install -g @lamalibre/lamaste-agent@4.0.0
|
|
267
|
+
LAMALIBRE_LAMASTE_ENROLLMENT_TOKEN=<token> \
|
|
268
|
+
lamaste-agent setup --label laptop --panel-url https://203.0.113.42:9292
|
|
269
|
+
```
|
|
270
|
+
|
|
271
|
+
Setup refuses to run from `npx`: it installs a timer that runs the installed agent every 30 seconds, and an `npx` copy can vanish from npm's cache. Setup generates the agent's key locally, prepares the Chisel client as a background service (launchd on macOS, a systemd user unit on Linux) that connects to `https://tunnel.example.com:443`, verifying the server's TLS certificate, and installs the sync timer that picks up tunnel changes from the panel. Until a tunnel is assigned to the agent the Chisel client stays stopped — it has nothing to carry. See the [Agent Setup](../02-guides/agent-setup.md) guide for details, including the one-time `loginctl enable-linger` step on headless Linux machines.
|
|
272
|
+
|
|
273
|
+
---
|
|
274
|
+
|
|
275
|
+
### Step 8: Create Your First Tunnel
|
|
276
|
+
|
|
277
|
+
In the management panel, navigate to **Tunnels** and click **Add Tunnel**.
|
|
278
|
+
|
|
279
|
+
Fill in the tunnel details:
|
|
280
|
+
|
|
281
|
+
| Field | Example | Description |
|
|
282
|
+
| ----------- | ------------ | -------------------------------------------- |
|
|
283
|
+
| Subdomain | `myapp` | Creates `myapp.example.com` |
|
|
284
|
+
| Port | `8001` | The port your app listens on (on the agent) |
|
|
285
|
+
| Agent | `laptop` | The agent that carries the tunnel (required) |
|
|
286
|
+
| Description | `My web app` | Optional label |
|
|
287
|
+
|
|
288
|
+
Click **Add Tunnel**. The panel:
|
|
289
|
+
|
|
290
|
+
1. Issues a TLS certificate for `myapp.example.com`
|
|
291
|
+
2. Writes an nginx vhost for `myapp.example.com` and reloads nginx
|
|
292
|
+
3. Grants the agent `laptop` — and only that agent — port 8001 on the Chisel server
|
|
293
|
+
|
|
294
|
+
There is nothing to run on the agent: its sync timer picks up the new tunnel within about 30 seconds and starts the Chisel client. (To apply it at once, run `lamaste-agent update` on the agent.)
|
|
295
|
+
|
|
296
|
+
The agent's Chisel client then reverse-forwards `127.0.0.1:8001` on the server to `127.0.0.1:8001` on your machine.
|
|
297
|
+
|
|
298
|
+
---
|
|
299
|
+
|
|
300
|
+
### Step 9: Test It
|
|
301
|
+
|
|
302
|
+
Open a browser and go to:
|
|
303
|
+
|
|
304
|
+
```
|
|
305
|
+
https://myapp.example.com
|
|
306
|
+
```
|
|
307
|
+
|
|
308
|
+
You will see the Authelia login page. Log in with the credentials created during onboarding (username + TOTP code from your authenticator app).
|
|
309
|
+
|
|
310
|
+
After authenticating, you see your local web app, served through the tunnel.
|
|
311
|
+
|
|
312
|
+
---
|
|
313
|
+
|
|
314
|
+
### Step 10: Disconnect SSH
|
|
315
|
+
|
|
316
|
+
Go back to your SSH terminal and type:
|
|
317
|
+
|
|
318
|
+
```bash
|
|
319
|
+
exit
|
|
320
|
+
```
|
|
321
|
+
|
|
322
|
+
You are done with SSH. Everything from here on is managed through the browser panel at `https://203.0.113.42:9292`.
|
|
323
|
+
|
|
324
|
+
If you ever need SSH again (disaster recovery, manual debugging), it is still available on port 22 with key-based authentication. But for normal operations, you will never need it.
|
|
325
|
+
|
|
326
|
+
---
|
|
327
|
+
|
|
328
|
+
### What You Have Now
|
|
329
|
+
|
|
330
|
+
```
|
|
331
|
+
Your Mac DigitalOcean Droplet Internet
|
|
332
|
+
┌──────────┐ WebSocket tunnel ┌──────────────────┐ ┌─────────┐
|
|
333
|
+
│ Web app │◄────────────────────►│ nginx + Chisel │◄─────────│ Visitors│
|
|
334
|
+
│ :8001 │ (encrypted, auto- │ + Authelia (2FA) │ HTTPS │ │
|
|
335
|
+
│ │ reconnecting) │ + Let's Encrypt │ │ │
|
|
336
|
+
└──────────┘ └──────────────────┘ └─────────┘
|
|
337
|
+
Admin: https://203.0.113.42:9292 (mTLS)
|
|
338
|
+
App: https://myapp.example.com (2FA)
|
|
339
|
+
```
|
|
340
|
+
|
|
341
|
+
## For Developers
|
|
342
|
+
|
|
343
|
+
### Installer CLI Flags
|
|
344
|
+
|
|
345
|
+
The installer accepts optional flags:
|
|
346
|
+
|
|
347
|
+
```bash
|
|
348
|
+
npx @lamalibre/create-lamaste@4.0.0 [flags]
|
|
349
|
+
```
|
|
350
|
+
|
|
351
|
+
| Flag | Effect |
|
|
352
|
+
| --------------- | ----------------------------------------------- |
|
|
353
|
+
| `--help`, `-h` | Print help message and exit |
|
|
354
|
+
| `--yes`, `-y` | Skip the confirmation prompt |
|
|
355
|
+
| `--skip-harden` | Skip OS hardening (swap, UFW, fail2ban, SSH) |
|
|
356
|
+
| `--dev` | Allow private/non-routable IP addresses |
|
|
357
|
+
| `--force-full` | Run full installation even on existing installs |
|
|
358
|
+
| `--uninstall` | Print manual removal guide and exit |
|
|
359
|
+
|
|
360
|
+
The `--dev` flag is useful for testing on local VMs that do not have public IP addresses.
|
|
361
|
+
|
|
362
|
+
The `--skip-harden` flag is useful when re-running the installer on a machine that was already hardened, or when you want to manage hardening separately.
|
|
363
|
+
|
|
364
|
+
### Re-running the Installer
|
|
365
|
+
|
|
366
|
+
The installer is idempotent. Running it again on an existing installation:
|
|
367
|
+
|
|
368
|
+
- Preserves `panel.json` configuration (merges, does not overwrite)
|
|
369
|
+
- Skips mTLS certificate generation if certificates already exist
|
|
370
|
+
- Skips swap creation if swap is already active
|
|
371
|
+
- Skips UFW configuration if all required ports are already allowed
|
|
372
|
+
- Skips fail2ban if already configured and running
|
|
373
|
+
- Updates lamalibre-lamaste-serverd and lamaste-server-ui files
|
|
374
|
+
- Restarts the panel service
|
|
375
|
+
|
|
376
|
+
This means you can safely re-run the installer after an update to the `create-lamaste` package without losing your configuration or certificates.
|
|
377
|
+
|
|
378
|
+
### Development Mode
|
|
379
|
+
|
|
380
|
+
For local development without a VPS:
|
|
381
|
+
|
|
382
|
+
```bash
|
|
383
|
+
# Terminal 1: Start panel backend
|
|
384
|
+
cd packages/lamalibre-lamaste-serverd
|
|
385
|
+
CONFIG_FILE=../../dev/panel.json NODE_ENV=development node src/index.js
|
|
386
|
+
|
|
387
|
+
# Terminal 2: Start panel frontend (Vite dev server, proxies /api to :3100)
|
|
388
|
+
cd packages/lamaste-server-ui
|
|
389
|
+
npx vite
|
|
390
|
+
```
|
|
391
|
+
|
|
392
|
+
In development mode (`NODE_ENV=development` or `NODE_ENV` unset), the panel server skips mTLS client certificate verification, so you can access it without importing a certificate.
|
|
393
|
+
|
|
394
|
+
### Troubleshooting
|
|
395
|
+
|
|
396
|
+
**Browser does not prompt for certificate:**
|
|
397
|
+
|
|
398
|
+
- Make sure you imported the `.p12` into the correct keychain (System on macOS)
|
|
399
|
+
- Restart the browser completely (not just the tab)
|
|
400
|
+
- Check that the certificate is trusted (macOS: Keychain Access, find cert, Trust, Always Trust)
|
|
401
|
+
|
|
402
|
+
**Installer fails at "Detecting IP address":**
|
|
403
|
+
|
|
404
|
+
- The droplet must have a public IP address
|
|
405
|
+
- Use `--dev` flag for testing on private networks
|
|
406
|
+
|
|
407
|
+
**DNS verification fails:**
|
|
408
|
+
|
|
409
|
+
- DNS propagation can take up to 48 hours (usually minutes)
|
|
410
|
+
- Verify records with `dig example.com` or `nslookup example.com`
|
|
411
|
+
- Make sure you created both the `A` record and the wildcard `*.example.com` record
|
|
412
|
+
|
|
413
|
+
**Panel service fails to start:**
|
|
414
|
+
|
|
415
|
+
- Check logs: `journalctl -u lamalibre-lamaste-serverd -n 50`
|
|
416
|
+
- Verify config: `cat /etc/lamalibre/lamaste/panel.json`
|
|
417
|
+
- Check if port 3100 is in use: `ss -tlnp sport = :3100`
|
|
418
|
+
|
|
419
|
+
## Quick Reference
|
|
420
|
+
|
|
421
|
+
### Prerequisites Checklist
|
|
422
|
+
|
|
423
|
+
```
|
|
424
|
+
[ ] DigitalOcean account (or any cloud provider)
|
|
425
|
+
[ ] Domain name with DNS access
|
|
426
|
+
[ ] SSH key pair
|
|
427
|
+
[ ] Mac or Linux machine with outbound internet
|
|
428
|
+
[ ] A local web app running on some port
|
|
429
|
+
```
|
|
430
|
+
|
|
431
|
+
### Command Sequence
|
|
432
|
+
|
|
433
|
+
```bash
|
|
434
|
+
# 1. Create droplet (Ubuntu 24.04, 512MB, $4/mo)
|
|
435
|
+
# 2. SSH in and install
|
|
436
|
+
ssh root@203.0.113.42
|
|
437
|
+
apt install -y npm
|
|
438
|
+
npx @lamalibre/create-lamaste@4.0.0
|
|
439
|
+
|
|
440
|
+
# 3. Download cert (from your local machine)
|
|
441
|
+
scp root@203.0.113.42:/etc/lamalibre/lamaste/pki/client.p12 .
|
|
442
|
+
|
|
443
|
+
# 4. Import cert into browser, open panel
|
|
444
|
+
# https://203.0.113.42:9292
|
|
445
|
+
|
|
446
|
+
# 5. Complete onboarding wizard (domain, DNS, provision)
|
|
447
|
+
# 6. Enroll your machine as an agent (desktop app or lamaste-agent setup)
|
|
448
|
+
# 7. Create tunnel in management panel, carried by that agent (applied within ~30 s)
|
|
449
|
+
# 8. Visit https://myapp.example.com
|
|
450
|
+
# 9. Disconnect SSH forever
|
|
451
|
+
```
|
|
452
|
+
|
|
453
|
+
### Time Estimates
|
|
454
|
+
|
|
455
|
+
| Step | Time |
|
|
456
|
+
| ------------------- | ---------------------------------------- |
|
|
457
|
+
| Create droplet | 1 minute |
|
|
458
|
+
| Run installer | 2-3 minutes |
|
|
459
|
+
| Import certificate | 1 minute |
|
|
460
|
+
| Onboarding wizard | 3-5 minutes (depends on DNS propagation) |
|
|
461
|
+
| Create first tunnel | 1 minute |
|
|
462
|
+
| **Total** | **~10 minutes** |
|
|
463
|
+
|
|
464
|
+
### Related Documentation
|
|
465
|
+
|
|
466
|
+
- [What is Lamaste?](./what-is-lamaste.md) — overview and use cases
|
|
467
|
+
- [How It Works](./how-it-works.md) — architecture and data flow
|
|
468
|
+
- [Installation Guide](../02-guides/installation.md) — detailed installation reference
|
|
469
|
+
- [First Tunnel Guide](../02-guides/first-tunnel.md) — in-depth tunnel creation walkthrough
|
|
470
|
+
- [Agent Setup](../02-guides/agent-setup.md) — enroll macOS and Linux agents, boot persistence
|
|
471
|
+
- [Troubleshooting](../06-reference/troubleshooting.md) — common issues and solutions
|
|
472
|
+
- [Glossary](../06-reference/glossary.md) — A-Z term definitions
|
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
# What is Lamaste?
|
|
2
|
+
|
|
3
|
+
> Lamaste is a self-hosted secure tunneling platform that exposes web apps running behind a firewall through a cheap VPS, with zero-login admin access via client certificates.
|
|
4
|
+
|
|
5
|
+
## In Plain English
|
|
6
|
+
|
|
7
|
+
Imagine you have a computer at home running a web app — maybe a side project, a blog engine, or an internal tool. You want people on the internet to access it, but your home network is behind a router that blocks incoming connections.
|
|
8
|
+
|
|
9
|
+
The traditional solution is to rent a server in the cloud and deploy your app there. But that means maintaining a server, managing deployments, and paying for compute you might not need.
|
|
10
|
+
|
|
11
|
+
Lamaste takes a different approach. You rent the cheapest possible server (a $4/month DigitalOcean droplet) and use it as a **relay**. Your home computer connects _out_ to the relay through a secure tunnel, and when someone visits your domain, the relay forwards the request back through the tunnel to your app.
|
|
12
|
+
|
|
13
|
+
Think of it like a postal forwarding service. Your app stays at home, but mail gets forwarded to the right address.
|
|
14
|
+
|
|
15
|
+
The clever part: after the initial 5-minute setup, you never need to SSH into the server again. Everything — domain setup, user management, certificate renewal, tunnel configuration — happens through a browser-based admin panel protected by a client certificate (like a digital ID card that your browser presents automatically).
|
|
16
|
+
|
|
17
|
+
## For Users
|
|
18
|
+
|
|
19
|
+
Lamaste solves the problem of exposing local services to the internet securely. Here is what you get:
|
|
20
|
+
|
|
21
|
+
**What it does:**
|
|
22
|
+
|
|
23
|
+
- Exposes local web apps (any port) through HTTPS on your own domain
|
|
24
|
+
- Protects each app with TOTP two-factor authentication (Google Authenticator, Authy, etc.)
|
|
25
|
+
- Manages TLS certificates automatically via Let's Encrypt
|
|
26
|
+
- Provides a browser-based admin panel for everything — no SSH needed after setup
|
|
27
|
+
|
|
28
|
+
**What you need:**
|
|
29
|
+
|
|
30
|
+
- A Mac (or Linux machine) running the web apps you want to expose
|
|
31
|
+
- A $4/month DigitalOcean droplet (Ubuntu 24.04, 512MB RAM)
|
|
32
|
+
- A domain name (or use a managed subdomain)
|
|
33
|
+
|
|
34
|
+
**How setup works:**
|
|
35
|
+
|
|
36
|
+
**Option A: Manual setup (SSH)**
|
|
37
|
+
|
|
38
|
+
1. Create a fresh Ubuntu 24.04 droplet on DigitalOcean
|
|
39
|
+
2. SSH in once and run `npx @lamalibre/create-lamaste@4.0.0`
|
|
40
|
+
3. Download the client certificate it prints
|
|
41
|
+
4. Import the certificate into your browser
|
|
42
|
+
5. Open `https://<droplet-ip>:9292` — you are in the admin panel
|
|
43
|
+
6. Complete the onboarding wizard (domain, DNS, stack provisioning)
|
|
44
|
+
7. Create tunnels, add users, manage everything from the browser
|
|
45
|
+
8. Disconnect SSH. You never need it again.
|
|
46
|
+
|
|
47
|
+
**Option B: Desktop app cloud provisioning**
|
|
48
|
+
|
|
49
|
+
1. Install the desktop app (`npx @lamalibre/create-lamaste-desktop@4.0.0`)
|
|
50
|
+
2. Go to the Servers tab and click "Create a new server"
|
|
51
|
+
3. Enter your DigitalOcean API token — the app validates scopes and stores it securely in your OS credential store
|
|
52
|
+
4. Pick a region (the app measures latency to each) and a domain name
|
|
53
|
+
5. Click "Provision" — the app creates the droplet, installs Lamaste, downloads your certificate, and connects automatically
|
|
54
|
+
6. Manage everything from the desktop app or the browser panel
|
|
55
|
+
|
|
56
|
+
See the [Cloud Provisioning guide](../02-guides/cloud-provisioning.md) for a detailed walkthrough.
|
|
57
|
+
|
|
58
|
+
**Key design choices:**
|
|
59
|
+
|
|
60
|
+
- The admin panel always works via IP address (`:9292`), even if your domain goes down
|
|
61
|
+
- Client certificate authentication means zero-login — your browser proves identity at the TLS level
|
|
62
|
+
- All services run on the cheapest possible VPS (512MB RAM budget, carefully tuned)
|
|
63
|
+
|
|
64
|
+
## For Developers
|
|
65
|
+
|
|
66
|
+
Lamaste is a monorepo with several packages:
|
|
67
|
+
|
|
68
|
+
| Package | Technology | Purpose |
|
|
69
|
+
| --------------------------- | -------------------------- | --------------------------------------------------------------------- |
|
|
70
|
+
| `create-lamaste` | Node.js ESM, Listr2, execa | Zero-prompt installer CLI |
|
|
71
|
+
| `lamalibre-lamaste-serverd` | Fastify 5, Node.js ESM | REST API + WebSocket backend |
|
|
72
|
+
| `lamaste-server-ui` | React 18, Vite, Tailwind | Management UI (SPA) + shared admin components for desktop |
|
|
73
|
+
| `lamaste-agent` | Node.js ESM | Tunnel agent CLI (macOS & Linux) |
|
|
74
|
+
| `lamaste-desktop` | Tauri v2 (Rust + React) | Desktop app with service discovery, multi-server & cloud provisioning |
|
|
75
|
+
| `lamaste-agent-ui` | React 18 | Shared agent UI (pages, context, components) for desktop agent mode |
|
|
76
|
+
| `create-lamaste-desktop` | Node.js ESM | npx installer for the desktop app |
|
|
77
|
+
| `lamaste-tickets` | TypeScript, undici | SDK for agent-to-agent authorization |
|
|
78
|
+
| `lamaste-cloud` | TypeScript, undici | Cloud provider abstraction for server provisioning |
|
|
79
|
+
|
|
80
|
+
**Architecture summary:**
|
|
81
|
+
|
|
82
|
+
```
|
|
83
|
+
Internet → nginx (TLS + mTLS) → Panel Server (Fastify, :3100)
|
|
84
|
+
→ Authelia (TOTP 2FA, :9091)
|
|
85
|
+
→ Chisel Server (WebSocket tunnels, :9090)
|
|
86
|
+
↑
|
|
87
|
+
Chisel Client (on your machine, auto-reconnect)
|
|
88
|
+
↑
|
|
89
|
+
Your local web app (:8001, :3000, etc.)
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
All backend services bind `127.0.0.1` only — nginx is the sole public-facing service. The panel is protected by mTLS (client certificates), while tunneled apps are protected by Authelia (TOTP 2FA).
|
|
93
|
+
|
|
94
|
+
State is stored in JSON files (`/etc/lamalibre/lamaste/panel.json`, `tunnels.json`) with atomic writes (write to temp → fsync → rename). No database is needed at this scale.
|
|
95
|
+
|
|
96
|
+
The installer (`npx @lamalibre/create-lamaste@4.0.0`) is completely non-interactive — it detects the environment, provisions everything, and prints a summary. All configuration happens through the browser-based onboarding wizard after installation.
|
|
97
|
+
|
|
98
|
+
## Quick Reference
|
|
99
|
+
|
|
100
|
+
| Item | Value |
|
|
101
|
+
| -------------------- | ------------------------------- |
|
|
102
|
+
| **Minimum VPS** | 512MB RAM, Ubuntu 24.04 |
|
|
103
|
+
| **Install command** | `npx @lamalibre/create-lamaste@4.0.0` |
|
|
104
|
+
| **Admin panel** | `https://<ip>:9292` (mTLS) |
|
|
105
|
+
| **Auth for admin** | Client certificate (zero-login) |
|
|
106
|
+
| **Auth for apps** | TOTP 2FA via Authelia |
|
|
107
|
+
| **Tunnel protocol** | WebSocket-over-HTTPS (Chisel) |
|
|
108
|
+
| **TLS certificates** | Let's Encrypt (auto-renewing) |
|
|
109
|
+
| **State storage** | JSON files (no database) |
|
|
110
|
+
| **RAM usage** | ~245MB total (all services) |
|
|
111
|
+
| **npm package** | `@lamalibre/create-lamaste@4.0.0` |
|
|
112
|
+
| **License** | Polyform Noncommercial 1.0.0 |
|