openship 0.3.0 → 0.4.1

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.
Files changed (82) hide show
  1. package/README.md +104 -61
  2. package/dist/bare-ITM45QBX.js +18 -0
  3. package/dist/bowser-MFQA6OS4.js +2821 -0
  4. package/dist/chunk-3U4SPZD5.js +241 -0
  5. package/dist/chunk-46YJFP4S.js +1771 -0
  6. package/dist/chunk-4CQWT2WL.js +116 -0
  7. package/dist/chunk-4FABQGQP.js +23 -0
  8. package/dist/chunk-4LEL3H2Z.js +84 -0
  9. package/dist/chunk-4MG3BVHE.js +326 -0
  10. package/dist/chunk-4VNS5WPM.js +42 -0
  11. package/dist/chunk-5N7VUGL6.js +2094 -0
  12. package/dist/chunk-5ZCKQ2MI.js +1360 -0
  13. package/dist/chunk-6ERIMTBC.js +1412 -0
  14. package/dist/chunk-7UOB5GGQ.js +132 -0
  15. package/dist/chunk-BUBSSKO6.js +1384 -0
  16. package/dist/chunk-E6W2JMMU.js +341 -0
  17. package/dist/chunk-E77LJWJK.js +1535 -0
  18. package/dist/chunk-F4DFVG6Q.js +573 -0
  19. package/dist/chunk-HFYDYK4D.js +1092 -0
  20. package/dist/chunk-JR2OCMJA.js +46 -0
  21. package/dist/chunk-JUJBBF5U.js +746 -0
  22. package/dist/chunk-JZLNHGLW.js +19145 -0
  23. package/dist/chunk-KD7VO4LG.js +2617 -0
  24. package/dist/chunk-LBFH7THC.js +435 -0
  25. package/dist/chunk-NB2VEIWG.js +129 -0
  26. package/dist/chunk-OJE6YWPQ.js +2866 -0
  27. package/dist/chunk-QKFRZNKN.js +4941 -0
  28. package/dist/chunk-QWFNE5NS.js +13354 -0
  29. package/dist/chunk-S6DSRLNE.js +121 -0
  30. package/dist/chunk-TEYJYSMT.js +409 -0
  31. package/dist/chunk-U2DPZSXA.js +112 -0
  32. package/dist/chunk-WJPCBU7Z.js +3147 -0
  33. package/dist/chunk-XIFRMKYT.js +13 -0
  34. package/dist/chunk-XVSAUO2I.js +7946 -0
  35. package/dist/chunk-Y37KHU7L.js +31 -0
  36. package/dist/chunk-YL67EWYZ.js +416 -0
  37. package/dist/chunk-ZKJOFWBJ.js +1879 -0
  38. package/dist/cloud-JMPHO3CW.js +7 -0
  39. package/dist/cloud-W5G6YXAY.js +24 -0
  40. package/dist/dist-L3MPOWCA.js +65 -0
  41. package/dist/dist-es-4C322O5D.js +22 -0
  42. package/dist/dist-es-GTAMF674.js +87 -0
  43. package/dist/dist-es-KE56MWYO.js +169 -0
  44. package/dist/dist-es-NRZIQY5B.js +484 -0
  45. package/dist/dist-es-WZCR7DHQ.js +317 -0
  46. package/dist/dist-es-XQCOTGC7.js +376 -0
  47. package/dist/dist-es-ZW3HFQUM.js +69 -0
  48. package/dist/docker-3FVJMFC3.js +12 -0
  49. package/dist/docker-edge-executor-ZIWAZWPL.js +9 -0
  50. package/dist/edge-import-W2D4L6HL.js +39 -0
  51. package/dist/event-streams-7LGDL56D.js +42 -0
  52. package/dist/executor-J7BHW5HF.js +26 -0
  53. package/dist/index.js +2450 -3484
  54. package/dist/loadSso-N273C5I7.js +577 -0
  55. package/dist/nginx-YZWKYKQU.js +16 -0
  56. package/dist/noop-RRNCIUI5.js +7 -0
  57. package/dist/openresty-lua-HAO4EUDY.js +32 -0
  58. package/dist/server/index.js +230533 -217891
  59. package/dist/server/migrations/0057_complete_prism.sql +18 -0
  60. package/dist/server/migrations/0058_add_server_is_local.sql +1 -0
  61. package/dist/server/migrations/0059_legal_fixer.sql +18 -0
  62. package/dist/server/migrations/0060_add_route_strategy_host_port.sql +3 -0
  63. package/dist/server/migrations/0061_notification_default_multi_kind.sql +3 -0
  64. package/dist/server/migrations/0062_add_incoming_webhook.sql +21 -0
  65. package/dist/server/migrations/0063_add_migration_logs.sql +1 -0
  66. package/dist/server/migrations/0064_add_migration_partial.sql +2 -0
  67. package/dist/server/migrations/0065_custom_app_template.sql +14 -0
  68. package/dist/server/migrations/0066_ensure_migration_partial_columns.sql +2 -0
  69. package/dist/server/migrations/0067_webhook_delivery.sql +28 -0
  70. package/dist/server/migrations/0068_add_migration_target_volumes.sql +1 -0
  71. package/dist/server/migrations/0069_add_project_composite_routes.sql +1 -0
  72. package/dist/server/migrations/0070_forward_git_to_server.sql +1 -0
  73. package/dist/server/migrations/meta/0057_snapshot.json +9326 -0
  74. package/dist/server/migrations/meta/0058_snapshot.json +9333 -0
  75. package/dist/server/migrations/meta/0059_snapshot.json +9495 -0
  76. package/dist/server/migrations/meta/0060_snapshot.json +9515 -0
  77. package/dist/server/migrations/meta/_journal.json +99 -1
  78. package/dist/setup-5X3WEEHA.js +14 -0
  79. package/dist/signin-DR462ERO.js +663 -0
  80. package/dist/sso-oidc-VBZLJUK5.js +830 -0
  81. package/dist/sts-EJLZ4Z77.js +1422 -0
  82. package/package.json +6 -2
package/README.md CHANGED
@@ -2,7 +2,13 @@
2
2
 
3
3
  <p align="center">
4
4
  Open-source, self-hostable deployment platform with built-in CI/CD.<br>
5
- Push code, ship containers, manage infrastructure from a desktop app, web dashboard, or CLI.
5
+ Point it at a repo — it builds, ships, routes, and TLS-terminates your app. Drive it from a desktop app, web dashboard, or CLI.
6
+ </p>
7
+
8
+ <p align="center">
9
+ <a href="https://trendshift.io/repositories/38817?utm_source=repository-badge&utm_medium=badge&utm_campaign=badge-repository-38817">
10
+ <img src="https://trendshift.io/api/badge/repositories/38817" alt="Trendshift" width="250" height="55" />
11
+ </a>
6
12
  </p>
7
13
 
8
14
  <p align="center">
@@ -13,8 +19,8 @@
13
19
 
14
20
  <p align="center">
15
21
  <a href="#quick-start">Quick Start</a> ·
16
- <a href="#features">Features</a> ·
17
- <a href="#three-interfaces">Interfaces</a> ·
22
+ <a href="#how-it-works">How It Works</a> ·
23
+ <a href="#interfaces">Interfaces</a> ·
18
24
  <a href="https://openship.io/docs">Docs</a> ·
19
25
  <a href="CONTRIBUTING.md">Contributing</a>
20
26
  </p>
@@ -28,6 +34,7 @@
28
34
  <a href="docs/i18n/README.ja.md"><img src="https://img.shields.io/badge/lang-日本語-555" alt="日本語" /></a>
29
35
  <a href="docs/i18n/README.pt.md"><img src="https://img.shields.io/badge/lang-Português-555" alt="Português" /></a>
30
36
  <a href="docs/i18n/README.de.md"><img src="https://img.shields.io/badge/lang-Deutsch-555" alt="Deutsch" /></a>
37
+ <a href="docs/i18n/README.tr.md"><img src="https://img.shields.io/badge/lang-Türkçe-555" alt="Türkçe" /></a>
31
38
  </p>
32
39
 
33
40
  <p align="center">
@@ -38,11 +45,20 @@
38
45
 
39
46
  ## Quick Start
40
47
 
41
- Pick by how you work **solo desktop app**, **team / always-on CLI on a server**.
48
+ There's one decision to make first: **how you run Openship itself** (the control plane). Everything else is the same afterwards.
49
+
50
+ | If you're… | Run Openship as | Where your apps run |
51
+ |---|---|---|
52
+ | **Solo, one machine, no ops** | **Desktop app** | A server you connect over SSH, or Openship Cloud |
53
+ | **A team — or you want push-to-deploy / to host apps on your own box** | **Self-hosted server** (`openship up`) | On that box (Compose mode) — or out to another server / Cloud (bare mode) |
54
+ | **Not interested in running anything** | **Openship Cloud** | Managed sandboxes, zero setup |
55
+
56
+ > [!TIP]
57
+ > **Solo? Use the desktop app.** It runs Openship's control plane on your own machine *only while the app is open* — nothing is left running on an always-on server, nothing is exposed publicly. You only need an always-on server install once you want **push-to-deploy (CI/CD)**, **team access**, or to **host apps on that box** — the things that need a public, always-on endpoint.
42
58
 
43
59
  ### Solo — desktop app
44
60
 
45
- The control plane runs on your machine and drives your servers over SSH; nothing of Openship is exposed publicly. Download, open, done — no terminal needed:
61
+ The control plane runs locally and drives your servers over SSH. No login, no terminal, no public surface — download, open, done:
46
62
 
47
63
  | Platform | Download |
48
64
  |---|---|
@@ -51,58 +67,100 @@ The control plane runs on your machine and drives your servers over SSH; nothing
51
67
  | **Windows** | [Openship-win32-x64.zip](https://github.com/oblien/openship/releases/latest/download/Openship-win32-x64.zip) |
52
68
  | **Linux** | [Openship.AppImage](https://github.com/oblien/openship/releases/latest/download/Openship.AppImage) |
53
69
 
54
- Linux: `chmod +x Openship.AppImage && ./Openship.AppImage`. Links always point at the newest release.
70
+ Linux: `chmod +x Openship.AppImage && ./Openship.AppImage`. Already have the CLI? `openship install` fetches and launches it. Links always point at the newest release.
71
+
72
+ From the desktop app you connect a server (SSH) or Openship Cloud and deploy to it — the app itself doesn't host public apps on your laptop.
55
73
 
56
- ### Team / always-on — CLI on a server
74
+ ### Team / always-on — self-hosted server
57
75
 
58
- Install the CLI (it bundles the API + dashboard), then run **`openship`** — an interactive wizard creates the first admin, wires your domain, and installs itself as a boot service. Run it again anytime to manage the instance.
76
+ Install the CLI (it bundles the API + dashboard), then run **`openship`** — an interactive wizard creates the first admin, wires your domain, and installs Openship as a boot service. Run it again anytime to manage the instance.
59
77
 
60
78
  ```bash
61
- curl -fsSL https://get.openship.io | sh # install (or: npm i -g openship)
62
- openship # interactive setup, then control panel
79
+ curl -fsSL https://get.openship.io | sh # install (or: npm i -g openship)
80
+ openship # guided setup, then control panel
63
81
  ```
64
82
 
65
- For CI / headless boxes, skip the wizard and drive `openship up` directly — same background service, boots and auto-restarts:
83
+ For CI / headless boxes, skip the wizard and drive `openship up` directly:
66
84
 
67
85
  ```bash
68
- openship up # background service on this machine
69
- openship up --public-url https://openship.example.com # + expose on your domain (edge + TLS handled)
86
+ openship up # install + start as a background service (boots + auto-restarts)
87
+ openship up --public-url https://openship.example.com # + serve the dashboard on your domain (edge + TLS handled)
70
88
  ```
71
89
 
72
- `openship open` opens the dashboard · `openship stop` stops it · `openship update` upgrades · `openship up --foreground` runs attached.
90
+ **`openship up` picks how it runs for you:**
91
+
92
+ - **On Linux with Docker → Compose mode** (the default). Brings up the full stack — Postgres, Redis, API, dashboard, and a containerized **OpenResty edge on :80/:443** — from published images. This is the flavor that **hosts your deployed apps on the same box**, with automatic domains + Let's Encrypt TLS. Force it with `--compose`.
93
+ - **Everywhere else → bare mode** (macOS, Windows, or Linux without Docker). A single lightweight process with an embedded database — an always-on control plane that **deploys apps out to a server (SSH) or Cloud**, like the desktop app but always on and login-required. Force it with `--bare`.
94
+
95
+ A self-hosted instance **always requires login** (the admin you create in setup). `openship open` opens the dashboard · `openship stop` stops it · `openship update` upgrades · `openship up --foreground` runs attached.
96
+
97
+ > **Preview an unreleased build (dev).** To run the CLI built straight from source — a branch, tag, or `main` ahead of the next release — install the from-source build:
98
+ >
99
+ > ```bash
100
+ > curl -fsSL https://get.openship.io/dev | sh # or: OPENSHIP_REF=my-branch curl ... | sh
101
+ > openship-dev # same CLI, built from source
102
+ > openship-dev update # pull latest source + rebuild (no release needed)
103
+ > ```
104
+ >
105
+ > It installs as a **separate `openship-dev`** command with its own isolated home (`~/.openship-dev`) and boot service, so your production `openship` and its data are never touched. Needs Bun + git; it's an unverified dev build (the dashboard compile wants real RAM/CPU) — not a production path.
73
106
 
74
107
  **Deploy a project:**
75
108
 
76
109
  ```bash
77
110
  cd your-project
78
- openship init # link this directory to a project
111
+ openship init # link this directory to a project
79
112
  openship deploy
80
113
  ```
81
114
 
82
- Full server guide + complete CLI reference: **[docs/installation.md](docs/installation.md)**.
115
+ Full server guide + complete CLI reference: **[openship.io/docs](https://openship.io/docs)**.
83
116
 
84
117
  <details>
85
- <summary>Advanced: run from source with Docker Compose (not the recommended path)</summary>
118
+ <summary>Self-host with raw Docker Compose (no CLI)</summary>
86
119
 
87
- Heavier than the CLI, and the compose stack gives the control-plane container access to the host Docker daemon (host-privileged) — use it only if you specifically need a containerized control plane. The CLI and desktop app above are the supported installs.
120
+ The self-hosted stack lives in **`docker/docker-compose.yml`** and **pulls** published images from GitHub Container Registry (`ghcr.io/oblien/*`) — no build tooling, no monorepo compile. Run it from the repo root:
88
121
 
89
122
  ```bash
90
123
  git clone https://github.com/oblien/openship.git && cd openship
91
- cp .env.example .env
92
- docker compose up -d
124
+ cp .env.example .env # then edit
125
+ docker compose --env-file .env -f docker/docker-compose.yml up -d
93
126
  ```
94
127
 
128
+ The stack is **postgres + redis + api + dashboard + edge**. The `edge` is OpenResty on **:80/:443** as a container (`network_mode: host`) — routing + Let's Encrypt, no bare host install. **Linux only** (host networking); on mac/win use `openship up` (bare). The `api` container mounts the host Docker socket so the control plane can build + run your apps as host containers — it's host-privileged through the socket, so run it only on a trusted host.
129
+
130
+ **Upgrade:** pin `OPENSHIP_VERSION` in `.env` for reproducible pulls, then `docker compose --env-file .env -f docker/docker-compose.yml pull && … up -d` (or just `openship update`). **Build from source instead:** add `-f docker/docker-compose.build.yml … up -d --build`.
131
+
132
+ > The **root** `docker-compose.yml` is a different file: it's the SaaS / from-source **control plane** (builds from source, ships the marketing site, no edge/socket). It does **not** self-host your apps — use `docker/docker-compose.yml` above or `openship up`.
133
+
95
134
  </details>
96
135
 
97
136
  ---
98
137
 
99
- ## What It Does
138
+ ## How It Works
100
139
 
101
- Point it at a repo. Openship detects your stack, builds it, configures everything, and ships itzero config files, zero pipelines, zero YAML.
140
+ Point Openship at a source a **GitHub repo**, a **local folder**, or a **prebuilt artifact**and it runs one pipeline end to end:
102
141
 
103
- Databases, domains, SSL, CDN, mail, backups all managed from one place.
142
+ 1. **Detect.** It reads your `package.json`, framework config, lockfiles, and any `docker-compose.yml` / `openship.json` to work out the stack, package manager, build/start commands, and port. Zero config files required; an `openship.json` overrides the guesses if you want control.
143
+ 2. **Build.** On the target server or locally on the orchestrator, into a Docker image or a bare release. The resolved config is frozen into a snapshot, so redeploys and rollbacks re-run *exactly* what shipped.
144
+ 3. **Run.** As a container (published on loopback only — never a public port) or a supervised host process.
145
+ 4. **Route + secure.** The OpenResty edge writes a reverse-proxy vhost to your domain and issues a Let's Encrypt certificate (HTTP-01). Because routing and TLS happen *after* the app is up, a DNS or cert hiccup surfaces as "action required" — it never fails the deploy or takes your app down.
146
+ 5. **Push-to-deploy.** A GitHub webhook re-runs the pipeline on every push to the tracked branch — rebuilding only the services a monorepo push actually touched.
104
147
 
105
- Solo devs shipping side projects and teams running production use the same tool.
148
+ Databases, domains, SSL, CDN, mail, and backups are managed from the same place. (Push-to-deploy and public domains need an always-on server or Cloud — a desktop/loopback instance has no public endpoint to receive webhooks.)
149
+
150
+ ---
151
+
152
+ ## Interfaces
153
+
154
+ Three ways to drive the same backend:
155
+
156
+ - **Desktop app** — full GUI, real-time logs, one-click everything. Best for solo.
157
+ - **Web dashboard** — the same UI in the browser, built for teams.
158
+ - **CLI** — scriptable and CI-friendly; also how you install and manage a self-hosted instance.
159
+
160
+ An **MCP** endpoint (for AI agents) and a **REST API** round it out for automation. Only routes that opt in are exposed as MCP tools, every call re-checks your permissions, and credential/token routes can never become tools. Full reference at [openship.io/docs](https://openship.io/docs).
161
+
162
+ > [!NOTE]
163
+ > The docs are actively being filled out. If something's missing or unclear, [contributions](CONTRIBUTING.md) are hugely welcome.
106
164
 
107
165
  ---
108
166
 
@@ -135,22 +193,9 @@ Same interface regardless of where you deploy.
135
193
 
136
194
  ---
137
195
 
138
- ## Three Interfaces
139
-
140
- - **Desktop app** — full GUI, real-time logs, one-click everything.
141
- - **Web dashboard** — the same UI in the browser, built for teams.
142
- - **CLI** — scriptable and CI-friendly.
143
-
144
- A **REST API** and **MCP** (AI agent protocol) round it out for automation and tooling integration. Full command and API reference at [openship.io/docs](https://openship.io/docs).
145
-
146
- > [!NOTE]
147
- > The docs are still a work in progress — we're actively filling them out. If something's missing or unclear, [contributions](CONTRIBUTING.md) are hugely welcome and help us get there faster.
148
-
149
- ---
150
-
151
196
  ## Status
152
197
 
153
- Production-ready core, actively developed.
198
+ Production-ready core, actively developed. Self-hosting is **free** (no billing).
154
199
 
155
200
  **Coming next:** multi-node clusters, load-balancing UI, private networking, advanced monitoring, and visual CI/CD pipelines.
156
201
 
@@ -162,29 +207,6 @@ See [CONTRIBUTING.md](CONTRIBUTING.md).
162
207
 
163
208
  ---
164
209
 
165
- ## Releasing
166
-
167
- Cut a release with the version script — it syncs every package's version,
168
- commits the bump, tags `vX.Y.Z`, and pushes:
169
-
170
- ```bash
171
- bun scripts/release.ts 0.2.0 # explicit version
172
- # or a bump keyword: patch | minor | major | rc (minor from 0.1.x → 0.2.0)
173
- ```
174
-
175
- Pushing the tag triggers [`.github/workflows/release.yml`](.github/workflows/release.yml), which:
176
-
177
- - builds the **macOS / Windows / Linux installers** and the server tarballs (with SHA-256 sidecars),
178
- - **publishes the `openship` CLI to npm** — via npm [OIDC trusted publishing](https://docs.npmjs.com/trusted-publishers) (no token), and
179
- - creates the **GitHub Release** with the built assets (notes come from the tag).
180
-
181
- To flag a release as **critical** (or add recommended/info advisories) in the
182
- in-app updater, add an entry to [`release-advisories.json`](release-advisories.json)
183
- **before** tagging — clients pull it pinned to the release tag. High-level notes
184
- live in [`CHANGELOG.md`](CHANGELOG.md).
185
-
186
- ---
187
-
188
210
  ## Security
189
211
 
190
212
  Found a vulnerability? We welcome your report — please disclose it **privately**,
@@ -198,7 +220,28 @@ Good-faith security research is **authorized** under our
198
220
  first reports.
199
221
 
200
222
  ---
223
+ ## ⭐ Star History
201
224
 
225
+ <p align="center">
226
+ <a href="https://star-history.com/#oblien/openship&Date">
227
+ <picture>
228
+ <source
229
+ media="(prefers-color-scheme: dark)"
230
+ srcset="https://api.star-history.com/svg?repos=oblien/openship&type=Date&theme=dark"
231
+ />
232
+ <source
233
+ media="(prefers-color-scheme: light)"
234
+ srcset="https://api.star-history.com/svg?repos=oblien/openship&type=Date"
235
+ />
236
+ <img
237
+ alt="Star History Chart"
238
+ src="https://api.star-history.com/svg?repos=oblien/openship&type=Date"
239
+ />
240
+ </picture>
241
+ </a>
242
+ </p>
243
+
244
+ ---
202
245
  ## License
203
246
 
204
247
  Openship is **open-source** software, licensed under the [Apache License 2.0](LICENSE).
@@ -0,0 +1,18 @@
1
+ import {
2
+ BareRuntime,
3
+ STATIC_RELEASE_BASE
4
+ } from "./chunk-ZKJOFWBJ.js";
5
+ import "./chunk-NB2VEIWG.js";
6
+ import "./chunk-3U4SPZD5.js";
7
+ import "./chunk-YL67EWYZ.js";
8
+ import "./chunk-E77LJWJK.js";
9
+ import "./chunk-U2DPZSXA.js";
10
+ import "./chunk-4MG3BVHE.js";
11
+ import "./chunk-4LEL3H2Z.js";
12
+ import "./chunk-4CQWT2WL.js";
13
+ import "./chunk-JZLNHGLW.js";
14
+ import "./chunk-4VNS5WPM.js";
15
+ export {
16
+ BareRuntime,
17
+ STATIC_RELEASE_BASE
18
+ };