openship 0.1.0 → 0.1.7
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/dist/index.d.ts +1 -0
- package/dist/index.js +5786 -0
- package/dist/server/index.js +324319 -0
- package/dist/server/migrations/0000_init.sql +666 -0
- package/dist/server/migrations/0001_brief_tomorrow_man.sql +47 -0
- package/dist/server/migrations/0002_funny_dazzler.sql +2 -0
- package/dist/server/migrations/0003_third_killer_shrike.sql +1 -0
- package/dist/server/migrations/0004_session_active_org_not_null.sql +10 -0
- package/dist/server/migrations/0005_warm_amazoness.sql +3 -0
- package/dist/server/migrations/0006_lumpy_joystick.sql +1 -0
- package/dist/server/migrations/0007_outgoing_maginty.sql +2 -0
- package/dist/server/migrations/0008_frozen_cutover.sql +3 -0
- package/dist/server/migrations/0009_credits_billing.sql +142 -0
- package/dist/server/migrations/0010_credit_grant_dedupe.sql +14 -0
- package/dist/server/migrations/0011_remove_credit_ledger.sql +23 -0
- package/dist/server/migrations/0012_smart_deploys_and_git_rollback.sql +81 -0
- package/dist/server/migrations/0013_fix_check_run_rollup_unique.sql +38 -0
- package/dist/server/migrations/0014_default_rollback_git.sql +9 -0
- package/dist/server/migrations/0015_billing_idempotency_grants.sql +41 -0
- package/dist/server/migrations/0016_github_auth_high_findings.sql +30 -0
- package/dist/server/migrations/0017_spooky_rumiko_fujikawa.sql +6 -0
- package/dist/server/migrations/0018_calm_shatterstar.sql +1 -0
- package/dist/server/migrations/0019_rename_workspace_install_to_prepare.sql +1 -0
- package/dist/server/migrations/0020_uneven_the_renegades.sql +13 -0
- package/dist/server/migrations/0021_shiny_firestar.sql +2 -0
- package/dist/server/migrations/0022_version_on_success_backfill.sql +6 -0
- package/dist/server/migrations/0023_productive_gorilla_man.sql +17 -0
- package/dist/server/migrations/0024_sleepy_peter_quill.sql +2 -0
- package/dist/server/migrations/0025_smooth_blue_shield.sql +1 -0
- package/dist/server/migrations/0026_mail_backup_source.sql +11 -0
- package/dist/server/migrations/0027_opposite_anthem.sql +6 -0
- package/dist/server/migrations/0028_stale_rogue.sql +18 -0
- package/dist/server/migrations/0029_bouncy_loners.sql +16 -0
- package/dist/server/migrations/0030_bright_darkstar.sql +6 -0
- package/dist/server/migrations/0031_conscious_catseye.sql +13 -0
- package/dist/server/migrations/0032_wet_mimic.sql +51 -0
- package/dist/server/migrations/0033_eminent_molly_hayes.sql +2 -0
- package/dist/server/migrations/meta/0000_snapshot.json +5110 -0
- package/dist/server/migrations/meta/0001_snapshot.json +5257 -0
- package/dist/server/migrations/meta/0002_snapshot.json +5279 -0
- package/dist/server/migrations/meta/0003_snapshot.json +5286 -0
- package/dist/server/migrations/meta/0004_snapshot.json +5286 -0
- package/dist/server/migrations/meta/0005_snapshot.json +5305 -0
- package/dist/server/migrations/meta/0006_snapshot.json +5311 -0
- package/dist/server/migrations/meta/0007_snapshot.json +5323 -0
- package/dist/server/migrations/meta/0016_snapshot.json +6345 -0
- package/dist/server/migrations/meta/0017_snapshot.json +6383 -0
- package/dist/server/migrations/meta/0018_snapshot.json +6390 -0
- package/dist/server/migrations/meta/0019_snapshot.json +6390 -0
- package/dist/server/migrations/meta/0020_snapshot.json +6497 -0
- package/dist/server/migrations/meta/0021_snapshot.json +6509 -0
- package/dist/server/migrations/meta/0022_snapshot.json +6509 -0
- package/dist/server/migrations/meta/0023_snapshot.json +6629 -0
- package/dist/server/migrations/meta/0024_snapshot.json +6641 -0
- package/dist/server/migrations/meta/0025_snapshot.json +6648 -0
- package/dist/server/migrations/meta/0026_snapshot.json +6750 -0
- package/dist/server/migrations/meta/0027_snapshot.json +6757 -0
- package/dist/server/migrations/meta/0028_snapshot.json +6895 -0
- package/dist/server/migrations/meta/0029_snapshot.json +7028 -0
- package/dist/server/migrations/meta/0030_snapshot.json +7066 -0
- package/dist/server/migrations/meta/0031_snapshot.json +7181 -0
- package/dist/server/migrations/meta/0032_snapshot.json +7570 -0
- package/dist/server/migrations/meta/0033_snapshot.json +7597 -0
- package/dist/server/migrations/meta/_journal.json +244 -0
- package/dist/server/pglite/pglite.data +0 -0
- package/dist/server/pglite/pglite.wasm +0 -0
- package/package.json +33 -21
- package/.env.example +0 -22
- package/.nvmrc +0 -1
- package/.prettierrc +0 -7
- package/CONTRIBUTING.md +0 -40
- package/README.md +0 -164
- package/apps/api/.env.example +0 -30
- package/apps/api/Dockerfile +0 -24
- package/apps/api/package.json +0 -37
- package/apps/api/src/app.ts +0 -26
- package/apps/api/src/config/env.ts +0 -39
- package/apps/api/src/config/index.ts +0 -1
- package/apps/api/src/index.ts +0 -8
- package/apps/api/src/middleware/auth.ts +0 -24
- package/apps/api/src/middleware/error-handler.ts +0 -21
- package/apps/api/src/middleware/index.ts +0 -3
- package/apps/api/src/middleware/rate-limiter.ts +0 -26
- package/apps/api/src/modules/auth/auth.controller.ts +0 -26
- package/apps/api/src/modules/auth/auth.routes.ts +0 -10
- package/apps/api/src/modules/auth/auth.schema.ts +0 -12
- package/apps/api/src/modules/auth/auth.service.ts +0 -23
- package/apps/api/src/modules/billing/billing.controller.ts +0 -60
- package/apps/api/src/modules/billing/billing.routes.ts +0 -26
- package/apps/api/src/modules/billing/billing.schema.ts +0 -9
- package/apps/api/src/modules/billing/billing.service.ts +0 -33
- package/apps/api/src/modules/deployments/deployment.controller.ts +0 -35
- package/apps/api/src/modules/deployments/deployment.routes.ts +0 -11
- package/apps/api/src/modules/deployments/deployment.schema.ts +0 -7
- package/apps/api/src/modules/deployments/deployment.service.ts +0 -23
- package/apps/api/src/modules/domains/domain.controller.ts +0 -21
- package/apps/api/src/modules/domains/domain.routes.ts +0 -9
- package/apps/api/src/modules/domains/domain.service.ts +0 -19
- package/apps/api/src/modules/health/health.routes.ts +0 -10
- package/apps/api/src/modules/projects/project.controller.ts +0 -29
- package/apps/api/src/modules/projects/project.routes.ts +0 -10
- package/apps/api/src/modules/projects/project.schema.ts +0 -9
- package/apps/api/src/modules/projects/project.service.ts +0 -23
- package/apps/api/src/modules/webhooks/webhook.controller.ts +0 -22
- package/apps/api/src/modules/webhooks/webhook.routes.ts +0 -12
- package/apps/api/src/modules/webhooks/webhook.service.ts +0 -11
- package/apps/api/tsconfig.json +0 -12
- package/apps/cli/package.json +0 -28
- package/apps/cli/src/commands/deploy.ts +0 -11
- package/apps/cli/src/commands/init.ts +0 -8
- package/apps/cli/src/commands/login.ts +0 -8
- package/apps/cli/src/commands/logs.ts +0 -9
- package/apps/cli/src/index.ts +0 -21
- package/apps/cli/src/lib/api-client.ts +0 -35
- package/apps/cli/tsconfig.json +0 -12
- package/apps/dashboard/Dockerfile +0 -24
- package/apps/dashboard/next.config.mjs +0 -6
- package/apps/dashboard/package.json +0 -28
- package/apps/dashboard/src/app/(auth)/layout.tsx +0 -6
- package/apps/dashboard/src/app/(auth)/login/page.tsx +0 -11
- package/apps/dashboard/src/app/(auth)/register/page.tsx +0 -10
- package/apps/dashboard/src/app/(dashboard)/billing/page.tsx +0 -10
- package/apps/dashboard/src/app/(dashboard)/deployments/page.tsx +0 -8
- package/apps/dashboard/src/app/(dashboard)/domains/page.tsx +0 -8
- package/apps/dashboard/src/app/(dashboard)/layout.tsx +0 -37
- package/apps/dashboard/src/app/(dashboard)/monitoring/page.tsx +0 -8
- package/apps/dashboard/src/app/(dashboard)/projects/page.tsx +0 -8
- package/apps/dashboard/src/app/(dashboard)/settings/page.tsx +0 -8
- package/apps/dashboard/src/app/globals.css +0 -3
- package/apps/dashboard/src/app/layout.tsx +0 -15
- package/apps/dashboard/src/app/page.tsx +0 -6
- package/apps/dashboard/tsconfig.json +0 -11
- package/apps/web/Dockerfile +0 -24
- package/apps/web/next.config.mjs +0 -6
- package/apps/web/package.json +0 -26
- package/apps/web/src/app/(marketing)/docs/page.tsx +0 -10
- package/apps/web/src/app/(marketing)/layout.tsx +0 -24
- package/apps/web/src/app/(marketing)/page.tsx +0 -2
- package/apps/web/src/app/(marketing)/pricing/page.tsx +0 -10
- package/apps/web/src/app/globals.css +0 -3
- package/apps/web/src/app/layout.tsx +0 -16
- package/apps/web/src/app/page.tsx +0 -10
- package/apps/web/tsconfig.json +0 -11
- package/docker-compose.yml +0 -87
- package/packages/adapters/package.json +0 -27
- package/packages/adapters/src/base-adapter.ts +0 -49
- package/packages/adapters/src/docker-adapter.ts +0 -43
- package/packages/adapters/src/index.ts +0 -4
- package/packages/adapters/src/oblien-adapter.ts +0 -46
- package/packages/adapters/src/registry.ts +0 -22
- package/packages/adapters/tsconfig.json +0 -9
- package/packages/core/package.json +0 -27
- package/packages/core/src/constants.ts +0 -28
- package/packages/core/src/errors.ts +0 -49
- package/packages/core/src/index.ts +0 -4
- package/packages/core/src/types.ts +0 -47
- package/packages/core/src/utils.ts +0 -35
- package/packages/core/tsconfig.json +0 -9
- package/packages/db/package.json +0 -32
- package/packages/db/prisma/schema.prisma +0 -160
- package/packages/db/src/index.ts +0 -11
- package/packages/db/tsconfig.json +0 -9
- package/packages/ui/package.json +0 -38
- package/packages/ui/src/components/badge.tsx +0 -29
- package/packages/ui/src/components/button.tsx +0 -44
- package/packages/ui/src/components/card.tsx +0 -26
- package/packages/ui/src/components/status-dot.tsx +0 -25
- package/packages/ui/src/globals.css +0 -18
- package/packages/ui/src/index.tsx +0 -8
- package/packages/ui/src/lib/cn.ts +0 -7
- package/packages/ui/tsconfig.json +0 -9
- package/pnpm-workspace.yaml +0 -4
- package/tooling/tsconfig/base.json +0 -19
- package/tooling/tsconfig/nextjs.json +0 -10
- package/tooling/tsconfig/node.json +0 -10
- package/tooling/tsconfig/package.json +0 -7
- package/turbo.json +0 -32
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { Command } from "commander";
|
|
2
|
-
|
|
3
|
-
export const deployCommand = new Command("deploy")
|
|
4
|
-
.description("Deploy the current project")
|
|
5
|
-
.option("--prod", "Deploy to production")
|
|
6
|
-
.option("--preview", "Create a preview deployment")
|
|
7
|
-
.action(async (opts) => {
|
|
8
|
-
// TODO: Read openship.json, upload or push, trigger deployment via API
|
|
9
|
-
const env = opts.prod ? "production" : "preview";
|
|
10
|
-
console.log(`Deploying to ${env}...`);
|
|
11
|
-
});
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { Command } from "commander";
|
|
2
|
-
|
|
3
|
-
export const initCommand = new Command("init")
|
|
4
|
-
.description("Initialize an Openship project in the current directory")
|
|
5
|
-
.action(async () => {
|
|
6
|
-
// TODO: Create openship.json config, detect framework, link to account
|
|
7
|
-
console.log("Initializing Openship project...");
|
|
8
|
-
});
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { Command } from "commander";
|
|
2
|
-
|
|
3
|
-
export const loginCommand = new Command("login")
|
|
4
|
-
.description("Authenticate with your Openship account")
|
|
5
|
-
.action(async () => {
|
|
6
|
-
// TODO: Open browser for OAuth or prompt for API token
|
|
7
|
-
console.log("Logging in...");
|
|
8
|
-
});
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { Command } from "commander";
|
|
2
|
-
|
|
3
|
-
export const logsCommand = new Command("logs")
|
|
4
|
-
.description("Stream deployment logs")
|
|
5
|
-
.argument("[deploymentId]", "Deployment ID (defaults to latest)")
|
|
6
|
-
.action(async (deploymentId?: string) => {
|
|
7
|
-
// TODO: Connect to API and stream logs
|
|
8
|
-
console.log(`Streaming logs for ${deploymentId || "latest deployment"}...`);
|
|
9
|
-
});
|
package/apps/cli/src/index.ts
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
|
|
3
|
-
import { Command } from "commander";
|
|
4
|
-
import { deployCommand } from "./commands/deploy";
|
|
5
|
-
import { loginCommand } from "./commands/login";
|
|
6
|
-
import { initCommand } from "./commands/init";
|
|
7
|
-
import { logsCommand } from "./commands/logs";
|
|
8
|
-
|
|
9
|
-
const program = new Command();
|
|
10
|
-
|
|
11
|
-
program
|
|
12
|
-
.name("openship")
|
|
13
|
-
.description("Openship CLI — deploy from your terminal")
|
|
14
|
-
.version("0.1.0");
|
|
15
|
-
|
|
16
|
-
program.addCommand(initCommand);
|
|
17
|
-
program.addCommand(loginCommand);
|
|
18
|
-
program.addCommand(deployCommand);
|
|
19
|
-
program.addCommand(logsCommand);
|
|
20
|
-
|
|
21
|
-
program.parse();
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* CLI HTTP client — communicates with the Openship API.
|
|
3
|
-
*/
|
|
4
|
-
|
|
5
|
-
const DEFAULT_API_URL = "http://localhost:4000/api";
|
|
6
|
-
|
|
7
|
-
export function getApiUrl(): string {
|
|
8
|
-
return process.env.OPENSHIP_API_URL || DEFAULT_API_URL;
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
export async function apiRequest(path: string, options?: RequestInit) {
|
|
12
|
-
const url = `${getApiUrl()}${path}`;
|
|
13
|
-
const token = getStoredToken();
|
|
14
|
-
|
|
15
|
-
const res = await fetch(url, {
|
|
16
|
-
...options,
|
|
17
|
-
headers: {
|
|
18
|
-
"Content-Type": "application/json",
|
|
19
|
-
...(token ? { Authorization: `Bearer ${token}` } : {}),
|
|
20
|
-
...options?.headers,
|
|
21
|
-
},
|
|
22
|
-
});
|
|
23
|
-
|
|
24
|
-
if (!res.ok) {
|
|
25
|
-
const body = await res.json().catch(() => ({}));
|
|
26
|
-
throw new Error(body.error || `API error: ${res.status}`);
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
return res.json();
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
function getStoredToken(): string | null {
|
|
33
|
-
// TODO: Read token from ~/.openship/config.json
|
|
34
|
-
return null;
|
|
35
|
-
}
|
package/apps/cli/tsconfig.json
DELETED
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
# ─── Build stage ────────────────────────────────────────
|
|
2
|
-
FROM node:20-alpine AS builder
|
|
3
|
-
RUN corepack enable && corepack prepare pnpm@9.0.0 --activate
|
|
4
|
-
WORKDIR /app
|
|
5
|
-
|
|
6
|
-
COPY pnpm-workspace.yaml pnpm-lock.yaml* package.json ./
|
|
7
|
-
COPY tooling/ ./tooling/
|
|
8
|
-
COPY packages/ ./packages/
|
|
9
|
-
COPY apps/dashboard/ ./apps/dashboard/
|
|
10
|
-
|
|
11
|
-
RUN pnpm install --frozen-lockfile
|
|
12
|
-
RUN pnpm run build --filter=openship-dashboard...
|
|
13
|
-
|
|
14
|
-
# ─── Production stage ──────────────────────────────────
|
|
15
|
-
FROM node:20-alpine AS runner
|
|
16
|
-
WORKDIR /app
|
|
17
|
-
|
|
18
|
-
COPY --from=builder /app/apps/dashboard/.next/standalone ./
|
|
19
|
-
COPY --from=builder /app/apps/dashboard/.next/static ./.next/static
|
|
20
|
-
COPY --from=builder /app/apps/dashboard/public ./public
|
|
21
|
-
|
|
22
|
-
ENV NODE_ENV=production
|
|
23
|
-
EXPOSE 3001
|
|
24
|
-
CMD ["node", "server.js"]
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "openship-dashboard",
|
|
3
|
-
"version": "0.1.0",
|
|
4
|
-
"private": true,
|
|
5
|
-
"scripts": {
|
|
6
|
-
"dev": "next dev --port 3001",
|
|
7
|
-
"build": "next build",
|
|
8
|
-
"start": "next start",
|
|
9
|
-
"lint": "next lint",
|
|
10
|
-
"clean": "rm -rf .next .turbo node_modules"
|
|
11
|
-
},
|
|
12
|
-
"dependencies": {
|
|
13
|
-
"openship-ui": "workspace:*",
|
|
14
|
-
"openship-core": "workspace:*",
|
|
15
|
-
"openship-db": "workspace:*",
|
|
16
|
-
"next": "^14.2.0",
|
|
17
|
-
"react": "^18.3.0",
|
|
18
|
-
"react-dom": "^18.3.0",
|
|
19
|
-
"next-auth": "^5.0.0-beta.0"
|
|
20
|
-
},
|
|
21
|
-
"devDependencies": {
|
|
22
|
-
"openship-tsconfig": "workspace:*",
|
|
23
|
-
"@types/node": "^20.0.0",
|
|
24
|
-
"@types/react": "^18.3.0",
|
|
25
|
-
"@types/react-dom": "^18.3.0",
|
|
26
|
-
"typescript": "^5.4.0"
|
|
27
|
-
}
|
|
28
|
-
}
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
export default function LoginPage() {
|
|
2
|
-
return (
|
|
3
|
-
<div className="flex min-h-screen items-center justify-center">
|
|
4
|
-
<div className="w-full max-w-sm rounded-lg border p-8">
|
|
5
|
-
<h1 className="mb-6 text-2xl font-bold">Sign in to Openship</h1>
|
|
6
|
-
{/* Auth form will go here — next-auth / credentials / OAuth */}
|
|
7
|
-
<p className="text-sm text-gray-500">Authentication coming soon.</p>
|
|
8
|
-
</div>
|
|
9
|
-
</div>
|
|
10
|
-
);
|
|
11
|
-
}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
export default function RegisterPage() {
|
|
2
|
-
return (
|
|
3
|
-
<div className="flex min-h-screen items-center justify-center">
|
|
4
|
-
<div className="w-full max-w-sm rounded-lg border p-8">
|
|
5
|
-
<h1 className="mb-6 text-2xl font-bold">Create an account</h1>
|
|
6
|
-
<p className="text-sm text-gray-500">Registration coming soon.</p>
|
|
7
|
-
</div>
|
|
8
|
-
</div>
|
|
9
|
-
);
|
|
10
|
-
}
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Dashboard shell layout — sidebar + top bar wrapper.
|
|
3
|
-
* All authenticated dashboard pages live under this layout.
|
|
4
|
-
*/
|
|
5
|
-
export default function DashboardLayout({ children }: { children: React.ReactNode }) {
|
|
6
|
-
return (
|
|
7
|
-
<div className="flex h-screen">
|
|
8
|
-
{/* Sidebar */}
|
|
9
|
-
<aside className="w-64 shrink-0 border-r bg-gray-50 p-4">
|
|
10
|
-
<div className="mb-8 text-lg font-bold">Openship</div>
|
|
11
|
-
<nav className="flex flex-col gap-1 text-sm">
|
|
12
|
-
<a href="/projects" className="rounded px-3 py-2 hover:bg-gray-200">
|
|
13
|
-
Projects
|
|
14
|
-
</a>
|
|
15
|
-
<a href="/deployments" className="rounded px-3 py-2 hover:bg-gray-200">
|
|
16
|
-
Deployments
|
|
17
|
-
</a>
|
|
18
|
-
<a href="/domains" className="rounded px-3 py-2 hover:bg-gray-200">
|
|
19
|
-
Domains
|
|
20
|
-
</a>
|
|
21
|
-
<a href="/monitoring" className="rounded px-3 py-2 hover:bg-gray-200">
|
|
22
|
-
Monitoring
|
|
23
|
-
</a>
|
|
24
|
-
<a href="/settings" className="rounded px-3 py-2 hover:bg-gray-200">
|
|
25
|
-
Settings
|
|
26
|
-
</a>
|
|
27
|
-
<a href="/billing" className="rounded px-3 py-2 hover:bg-gray-200">
|
|
28
|
-
Billing
|
|
29
|
-
</a>
|
|
30
|
-
</nav>
|
|
31
|
-
</aside>
|
|
32
|
-
|
|
33
|
-
{/* Main content */}
|
|
34
|
-
<main className="flex-1 overflow-y-auto p-6">{children}</main>
|
|
35
|
-
</div>
|
|
36
|
-
);
|
|
37
|
-
}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import type { Metadata } from "next";
|
|
2
|
-
import "./globals.css";
|
|
3
|
-
|
|
4
|
-
export const metadata: Metadata = {
|
|
5
|
-
title: "Dashboard — Openship",
|
|
6
|
-
description: "Manage your deployments, domains, and infrastructure.",
|
|
7
|
-
};
|
|
8
|
-
|
|
9
|
-
export default function RootLayout({ children }: { children: React.ReactNode }) {
|
|
10
|
-
return (
|
|
11
|
-
<html lang="en">
|
|
12
|
-
<body>{children}</body>
|
|
13
|
-
</html>
|
|
14
|
-
);
|
|
15
|
-
}
|
package/apps/web/Dockerfile
DELETED
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
# ─── Build stage ────────────────────────────────────────
|
|
2
|
-
FROM node:20-alpine AS builder
|
|
3
|
-
RUN corepack enable && corepack prepare pnpm@9.0.0 --activate
|
|
4
|
-
WORKDIR /app
|
|
5
|
-
|
|
6
|
-
COPY pnpm-workspace.yaml pnpm-lock.yaml* package.json ./
|
|
7
|
-
COPY tooling/ ./tooling/
|
|
8
|
-
COPY packages/ ./packages/
|
|
9
|
-
COPY apps/web/ ./apps/web/
|
|
10
|
-
|
|
11
|
-
RUN pnpm install --frozen-lockfile
|
|
12
|
-
RUN pnpm run build --filter=openship-web...
|
|
13
|
-
|
|
14
|
-
# ─── Production stage ──────────────────────────────────
|
|
15
|
-
FROM node:20-alpine AS runner
|
|
16
|
-
WORKDIR /app
|
|
17
|
-
|
|
18
|
-
COPY --from=builder /app/apps/web/.next/standalone ./
|
|
19
|
-
COPY --from=builder /app/apps/web/.next/static ./.next/static
|
|
20
|
-
COPY --from=builder /app/apps/web/public ./public
|
|
21
|
-
|
|
22
|
-
ENV NODE_ENV=production
|
|
23
|
-
EXPOSE 3000
|
|
24
|
-
CMD ["node", "server.js"]
|
package/apps/web/next.config.mjs
DELETED
package/apps/web/package.json
DELETED
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "openship-web",
|
|
3
|
-
"version": "0.1.0",
|
|
4
|
-
"private": true,
|
|
5
|
-
"scripts": {
|
|
6
|
-
"dev": "next dev --port 3000",
|
|
7
|
-
"build": "next build",
|
|
8
|
-
"start": "next start",
|
|
9
|
-
"lint": "next lint",
|
|
10
|
-
"clean": "rm -rf .next .turbo node_modules"
|
|
11
|
-
},
|
|
12
|
-
"dependencies": {
|
|
13
|
-
"openship-ui": "workspace:*",
|
|
14
|
-
"openship-core": "workspace:*",
|
|
15
|
-
"next": "^14.2.0",
|
|
16
|
-
"react": "^18.3.0",
|
|
17
|
-
"react-dom": "^18.3.0"
|
|
18
|
-
},
|
|
19
|
-
"devDependencies": {
|
|
20
|
-
"openship-tsconfig": "workspace:*",
|
|
21
|
-
"@types/node": "^20.0.0",
|
|
22
|
-
"@types/react": "^18.3.0",
|
|
23
|
-
"@types/react-dom": "^18.3.0",
|
|
24
|
-
"typescript": "^5.4.0"
|
|
25
|
-
}
|
|
26
|
-
}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
export default function DocsPage() {
|
|
2
|
-
return (
|
|
3
|
-
<main className="mx-auto max-w-5xl px-6 py-20">
|
|
4
|
-
<h1 className="text-4xl font-bold">Documentation</h1>
|
|
5
|
-
<p className="mt-4 text-gray-600">
|
|
6
|
-
Everything you need to get started with Openship.
|
|
7
|
-
</p>
|
|
8
|
-
</main>
|
|
9
|
-
);
|
|
10
|
-
}
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
export default function MarketingLayout({ children }: { children: React.ReactNode }) {
|
|
2
|
-
return (
|
|
3
|
-
<div className="min-h-screen">
|
|
4
|
-
{/* Marketing nav / header goes here */}
|
|
5
|
-
<header className="border-b px-6 py-4">
|
|
6
|
-
<nav className="mx-auto flex max-w-7xl items-center justify-between">
|
|
7
|
-
<span className="text-xl font-bold">Openship</span>
|
|
8
|
-
<div className="flex items-center gap-6">
|
|
9
|
-
<a href="/pricing" className="text-sm hover:underline">
|
|
10
|
-
Pricing
|
|
11
|
-
</a>
|
|
12
|
-
<a href="/docs" className="text-sm hover:underline">
|
|
13
|
-
Docs
|
|
14
|
-
</a>
|
|
15
|
-
<a href="/login" className="text-sm font-medium hover:underline">
|
|
16
|
-
Login
|
|
17
|
-
</a>
|
|
18
|
-
</div>
|
|
19
|
-
</nav>
|
|
20
|
-
</header>
|
|
21
|
-
{children}
|
|
22
|
-
</div>
|
|
23
|
-
);
|
|
24
|
-
}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
export default function PricingPage() {
|
|
2
|
-
return (
|
|
3
|
-
<main className="mx-auto max-w-5xl px-6 py-20">
|
|
4
|
-
<h1 className="text-4xl font-bold">Pricing</h1>
|
|
5
|
-
<p className="mt-4 text-gray-600">
|
|
6
|
-
Free to self-host. Simple, transparent pricing for our hosted cloud.
|
|
7
|
-
</p>
|
|
8
|
-
</main>
|
|
9
|
-
);
|
|
10
|
-
}
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import type { Metadata } from "next";
|
|
2
|
-
import "./globals.css";
|
|
3
|
-
|
|
4
|
-
export const metadata: Metadata = {
|
|
5
|
-
title: "Openship — Self-Hostable Deployment Platform",
|
|
6
|
-
description:
|
|
7
|
-
"Deploy anywhere. Open-source deployment platform you can self-host or use our cloud.",
|
|
8
|
-
};
|
|
9
|
-
|
|
10
|
-
export default function RootLayout({ children }: { children: React.ReactNode }) {
|
|
11
|
-
return (
|
|
12
|
-
<html lang="en">
|
|
13
|
-
<body>{children}</body>
|
|
14
|
-
</html>
|
|
15
|
-
);
|
|
16
|
-
}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
export default function HomePage() {
|
|
2
|
-
return (
|
|
3
|
-
<main className="flex min-h-screen flex-col items-center justify-center">
|
|
4
|
-
<h1 className="text-5xl font-bold tracking-tight">Openship</h1>
|
|
5
|
-
<p className="mt-4 text-lg text-gray-600">
|
|
6
|
-
The open-source deployment platform you can self-host or use our cloud.
|
|
7
|
-
</p>
|
|
8
|
-
</main>
|
|
9
|
-
);
|
|
10
|
-
}
|
package/apps/web/tsconfig.json
DELETED
package/docker-compose.yml
DELETED
|
@@ -1,87 +0,0 @@
|
|
|
1
|
-
# ──────────────────────────────────────────────────────────
|
|
2
|
-
# Openship — Self-Hosted Docker Compose
|
|
3
|
-
#
|
|
4
|
-
# Quick start:
|
|
5
|
-
# cp .env.example .env
|
|
6
|
-
# docker compose up -d
|
|
7
|
-
#
|
|
8
|
-
# This spins up the full Openship stack:
|
|
9
|
-
# • Dashboard (Next.js) → localhost:3001
|
|
10
|
-
# • Web / Landing → localhost:3000
|
|
11
|
-
# • API (Hono) → localhost:4000
|
|
12
|
-
# • PostgreSQL → localhost:5432
|
|
13
|
-
# • Redis → localhost:6379
|
|
14
|
-
# ──────────────────────────────────────────────────────────
|
|
15
|
-
|
|
16
|
-
version: "3.9"
|
|
17
|
-
|
|
18
|
-
services:
|
|
19
|
-
# ─── Database ─────────────────────────────────────────
|
|
20
|
-
postgres:
|
|
21
|
-
image: postgres:16-alpine
|
|
22
|
-
restart: unless-stopped
|
|
23
|
-
environment:
|
|
24
|
-
POSTGRES_USER: openship
|
|
25
|
-
POSTGRES_PASSWORD: openship
|
|
26
|
-
POSTGRES_DB: openship
|
|
27
|
-
ports:
|
|
28
|
-
- "5432:5432"
|
|
29
|
-
volumes:
|
|
30
|
-
- postgres_data:/var/lib/postgresql/data
|
|
31
|
-
|
|
32
|
-
# ─── Cache / Queue ───────────────────────────────────
|
|
33
|
-
redis:
|
|
34
|
-
image: redis:7-alpine
|
|
35
|
-
restart: unless-stopped
|
|
36
|
-
ports:
|
|
37
|
-
- "6379:6379"
|
|
38
|
-
volumes:
|
|
39
|
-
- redis_data:/data
|
|
40
|
-
|
|
41
|
-
# ─── API ──────────────────────────────────────────────
|
|
42
|
-
api:
|
|
43
|
-
build:
|
|
44
|
-
context: .
|
|
45
|
-
dockerfile: apps/api/Dockerfile
|
|
46
|
-
restart: unless-stopped
|
|
47
|
-
ports:
|
|
48
|
-
- "4000:4000"
|
|
49
|
-
environment:
|
|
50
|
-
NODE_ENV: production
|
|
51
|
-
PORT: 4000
|
|
52
|
-
CLOUD_MODE: "false"
|
|
53
|
-
DATABASE_URL: postgresql://openship:openship@postgres:5432/openship
|
|
54
|
-
REDIS_URL: redis://redis:6379
|
|
55
|
-
JWT_SECRET: change-me-in-production
|
|
56
|
-
depends_on:
|
|
57
|
-
- postgres
|
|
58
|
-
- redis
|
|
59
|
-
|
|
60
|
-
# ─── Dashboard ────────────────────────────────────────
|
|
61
|
-
dashboard:
|
|
62
|
-
build:
|
|
63
|
-
context: .
|
|
64
|
-
dockerfile: apps/dashboard/Dockerfile
|
|
65
|
-
restart: unless-stopped
|
|
66
|
-
ports:
|
|
67
|
-
- "3001:3001"
|
|
68
|
-
environment:
|
|
69
|
-
NODE_ENV: production
|
|
70
|
-
NEXT_PUBLIC_API_URL: http://api:4000/api
|
|
71
|
-
depends_on:
|
|
72
|
-
- api
|
|
73
|
-
|
|
74
|
-
# ─── Web / Landing ───────────────────────────────────
|
|
75
|
-
web:
|
|
76
|
-
build:
|
|
77
|
-
context: .
|
|
78
|
-
dockerfile: apps/web/Dockerfile
|
|
79
|
-
restart: unless-stopped
|
|
80
|
-
ports:
|
|
81
|
-
- "3000:3000"
|
|
82
|
-
environment:
|
|
83
|
-
NODE_ENV: production
|
|
84
|
-
|
|
85
|
-
volumes:
|
|
86
|
-
postgres_data:
|
|
87
|
-
redis_data:
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "openship-adapters",
|
|
3
|
-
"version": "0.1.0",
|
|
4
|
-
"type": "module",
|
|
5
|
-
"main": "dist/index.js",
|
|
6
|
-
"types": "dist/index.d.ts",
|
|
7
|
-
"exports": {
|
|
8
|
-
".": {
|
|
9
|
-
"import": "./dist/index.js",
|
|
10
|
-
"types": "./dist/index.d.ts"
|
|
11
|
-
}
|
|
12
|
-
},
|
|
13
|
-
"scripts": {
|
|
14
|
-
"build": "tsup src/index.ts --format esm --dts --clean",
|
|
15
|
-
"dev": "tsup src/index.ts --format esm --dts --watch",
|
|
16
|
-
"lint": "tsc --noEmit",
|
|
17
|
-
"clean": "rm -rf dist .turbo node_modules"
|
|
18
|
-
},
|
|
19
|
-
"dependencies": {
|
|
20
|
-
"openship-core": "workspace:*"
|
|
21
|
-
},
|
|
22
|
-
"devDependencies": {
|
|
23
|
-
"openship-tsconfig": "workspace:*",
|
|
24
|
-
"tsup": "^8.1.0",
|
|
25
|
-
"typescript": "^5.4.0"
|
|
26
|
-
}
|
|
27
|
-
}
|