Stage 0: governance scaffolding + monorepo bootstrap
Phase 1 foundation for the Stargue Publishing Engine (plan v2, BMAD
panel-reviewed 2026-04-19 — 1 APPROVE, 6 REVISE, 0 REJECT; all principles >=3).
- Governance doctrine adopted from DQMS
(.clinerules/12-foundational-principles.md,
.claude/hooks/gate-plan-exit.sh, .claude/skills/bmad-plan/SKILL.md)
- Bun workspaces + Turbo; apps/{mcp-linkedin,scheduler,admin};
packages/{schema,sanitize,linkedin-client,observability}
- Drizzle schema (content, publications, approvals, metrics,
linkedin_tokens, audit, outlet_feature_flags) with idempotency_key
UNIQUE and kill-switch table per TEA/dev panel revisions
- LinkedIn API canon: Posts API /rest/posts (not legacy UGC); OAuth
auth-code without PKCE; secretbox (not sealed-box); Community
Management API as separate approval gate from MDP
- Frontmatter Zod schema (status, language, outlets[], sanitize,
scheduled, version)
- Pino observability with PII redaction
- Expand-then-contract migration runbook
- Plan + panel verdicts mirrored to docs/plans/
- Deferred gates logged (Dokploy PaaS verification, LinkedIn Dev
Portal app registration)
bun install + bun run typecheck both exit 0 across 11 workspaces.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
32
apps/admin/package.json
Normal file
32
apps/admin/package.json
Normal file
@@ -0,0 +1,32 @@
|
||||
{
|
||||
"name": "@stargue/admin",
|
||||
"version": "0.1.0",
|
||||
"private": true,
|
||||
"type": "module",
|
||||
"scripts": {
|
||||
"build": "next build",
|
||||
"dev": "next dev -p 3002",
|
||||
"start": "next start -p 3002",
|
||||
"typecheck": "tsc --noEmit",
|
||||
"test": "vitest run",
|
||||
"lint": "next lint"
|
||||
},
|
||||
"dependencies": {
|
||||
"@stargue/schema": "workspace:*",
|
||||
"@stargue/sanitize": "workspace:*",
|
||||
"@stargue/observability": "workspace:*",
|
||||
"next": "^16.0.0",
|
||||
"react": "^19.0.0",
|
||||
"react-dom": "^19.0.0",
|
||||
"zod": "^3.23.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@axe-core/playwright": "^4.10.0",
|
||||
"@playwright/test": "^1.48.0",
|
||||
"@types/react": "^19.0.0",
|
||||
"@types/react-dom": "^19.0.0",
|
||||
"axe-core": "^4.10.0",
|
||||
"typescript": "^5.7.0",
|
||||
"vitest": "^2.1.0"
|
||||
}
|
||||
}
|
||||
2
apps/admin/src/index.ts
Normal file
2
apps/admin/src/index.ts
Normal file
@@ -0,0 +1,2 @@
|
||||
// Admin dashboard (Next.js App Router) — full implementation in Stage 5.
|
||||
export const ADMIN_APP_NAME = "@stargue/admin";
|
||||
24
apps/mcp-linkedin/package.json
Normal file
24
apps/mcp-linkedin/package.json
Normal file
@@ -0,0 +1,24 @@
|
||||
{
|
||||
"name": "@stargue/mcp-linkedin",
|
||||
"version": "0.1.0",
|
||||
"private": true,
|
||||
"type": "module",
|
||||
"scripts": {
|
||||
"build": "tsc --noEmit",
|
||||
"dev": "bun --watch src/server.ts",
|
||||
"typecheck": "tsc --noEmit",
|
||||
"test": "vitest run",
|
||||
"lint": "echo 'lint pending'"
|
||||
},
|
||||
"dependencies": {
|
||||
"@modelcontextprotocol/sdk": "1.0.3",
|
||||
"@stargue/linkedin-client": "workspace:*",
|
||||
"@stargue/schema": "workspace:*",
|
||||
"@stargue/observability": "workspace:*",
|
||||
"zod": "^3.23.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"vitest": "^2.1.0",
|
||||
"typescript": "^5.7.0"
|
||||
}
|
||||
}
|
||||
4
apps/mcp-linkedin/src/server.ts
Normal file
4
apps/mcp-linkedin/src/server.ts
Normal file
@@ -0,0 +1,4 @@
|
||||
// MCP server entry point. Full implementation in Stage 3.
|
||||
// MCP spec version pinned: 2024-11-05 (Streamable HTTP + stdio).
|
||||
export const MCP_SERVER_NAME = "@stargue/mcp-linkedin";
|
||||
export const MCP_SPEC_VERSION = "2024-11-05";
|
||||
24
apps/scheduler/package.json
Normal file
24
apps/scheduler/package.json
Normal file
@@ -0,0 +1,24 @@
|
||||
{
|
||||
"name": "@stargue/scheduler",
|
||||
"version": "0.1.0",
|
||||
"private": true,
|
||||
"type": "module",
|
||||
"scripts": {
|
||||
"build": "tsc --noEmit",
|
||||
"dev": "bun --watch src/worker.ts",
|
||||
"typecheck": "tsc --noEmit",
|
||||
"test": "vitest run",
|
||||
"lint": "echo 'lint pending'"
|
||||
},
|
||||
"dependencies": {
|
||||
"@stargue/linkedin-client": "workspace:*",
|
||||
"@stargue/schema": "workspace:*",
|
||||
"@stargue/observability": "workspace:*",
|
||||
"bullmq": "^5.30.0",
|
||||
"ioredis": "^5.4.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"vitest": "^2.1.0",
|
||||
"typescript": "^5.7.0"
|
||||
}
|
||||
}
|
||||
2
apps/scheduler/src/worker.ts
Normal file
2
apps/scheduler/src/worker.ts
Normal file
@@ -0,0 +1,2 @@
|
||||
// BullMQ worker entry point. Full implementation in Stage 4.
|
||||
export const SCHEDULER_NAME = "@stargue/scheduler";
|
||||
Reference in New Issue
Block a user