create-atlas-agent 0.2.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +69 -0
- package/index.ts +526 -0
- package/package.json +33 -0
- package/template/.env.example +49 -0
- package/template/Dockerfile +31 -0
- package/template/bin/atlas.ts +1092 -0
- package/template/bin/enrich.ts +551 -0
- package/template/data/.gitkeep +0 -0
- package/template/data/demo-sqlite.sql +372 -0
- package/template/data/demo.sql +371 -0
- package/template/docker-compose.yml +23 -0
- package/template/docs/deploy.md +341 -0
- package/template/eslint.config.mjs +18 -0
- package/template/fly.toml +46 -0
- package/template/gitignore +5 -0
- package/template/next.config.ts +8 -0
- package/template/package.json +55 -0
- package/template/postcss.config.mjs +8 -0
- package/template/public/.gitkeep +0 -0
- package/template/railway.json +13 -0
- package/template/render.yaml +19 -0
- package/template/semantic/catalog.yml +5 -0
- package/template/semantic/entities/.gitkeep +0 -0
- package/template/semantic/glossary.yml +6 -0
- package/template/semantic/metrics/.gitkeep +0 -0
- package/template/src/app/api/chat/route.ts +107 -0
- package/template/src/app/api/health/route.ts +97 -0
- package/template/src/app/error.tsx +24 -0
- package/template/src/app/globals.css +1 -0
- package/template/src/app/layout.tsx +19 -0
- package/template/src/app/page.tsx +650 -0
- package/template/src/global.d.ts +1 -0
- package/template/src/lib/agent.ts +112 -0
- package/template/src/lib/db/connection.ts +150 -0
- package/template/src/lib/providers.ts +63 -0
- package/template/src/lib/semantic.ts +53 -0
- package/template/src/lib/startup.ts +211 -0
- package/template/src/lib/tools/__tests__/sql.test.ts +538 -0
- package/template/src/lib/tools/explore-sandbox.ts +189 -0
- package/template/src/lib/tools/explore.ts +164 -0
- package/template/src/lib/tools/report.ts +33 -0
- package/template/src/lib/tools/sql.ts +202 -0
- package/template/src/types/vercel-sandbox.d.ts +54 -0
- package/template/tsconfig.json +41 -0
- package/template/vercel.json +3 -0
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
FROM oven/bun:1.3 AS base
|
|
2
|
+
|
|
3
|
+
FROM base AS deps
|
|
4
|
+
WORKDIR /app
|
|
5
|
+
COPY package.json bun.lock* ./
|
|
6
|
+
RUN bun ci --ignore-scripts
|
|
7
|
+
|
|
8
|
+
FROM base AS builder
|
|
9
|
+
WORKDIR /app
|
|
10
|
+
COPY --from=deps /app/node_modules ./node_modules
|
|
11
|
+
COPY . .
|
|
12
|
+
RUN bun run build
|
|
13
|
+
|
|
14
|
+
FROM base AS runner
|
|
15
|
+
WORKDIR /app
|
|
16
|
+
# NOTE: SQLite data is ephemeral in containers — lost on restart/redeploy
|
|
17
|
+
# unless a persistent volume is mounted. Use PostgreSQL for production.
|
|
18
|
+
ENV NODE_ENV=production
|
|
19
|
+
RUN echo "nodejs:x:1001:" >> /etc/group && \
|
|
20
|
+
echo "nextjs:x:1001:1001:nextjs:/app:/bin/sh" >> /etc/passwd
|
|
21
|
+
COPY --from=builder --chown=nextjs:nodejs /app/.next/standalone ./
|
|
22
|
+
COPY --from=builder --chown=nextjs:nodejs /app/.next/static ./.next/static
|
|
23
|
+
COPY --from=builder --chown=nextjs:nodejs /app/public ./public
|
|
24
|
+
COPY --from=builder --chown=nextjs:nodejs /app/semantic ./semantic
|
|
25
|
+
USER nextjs
|
|
26
|
+
EXPOSE 3000
|
|
27
|
+
ENV PORT=3000
|
|
28
|
+
ENV HOSTNAME=0.0.0.0
|
|
29
|
+
HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 \
|
|
30
|
+
CMD bun -e "try { const r = await fetch('http://localhost:3000/api/health'); if(!r.ok){console.error(r.status); process.exit(1)} } catch(e) { console.error(e.message); process.exit(1) }"
|
|
31
|
+
CMD ["bun", "server.js"]
|