Fix frontend build: compile React bundle properly
All checks were successful
Build and Push Frontend / build (push) Successful in 22s
All checks were successful
Build and Push Frontend / build (push) Successful in 22s
- Build TypeScript/React to JavaScript bundle - Serve compiled main.js and main.css - Update HTML to load compiled assets - Add build step to Dockerfile Co-Authored-By: Claude Sonnet 4.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -11,6 +11,9 @@ RUN bun install --frozen-lockfile --production
|
||||
# Copy source code
|
||||
COPY . .
|
||||
|
||||
# Build the React bundle
|
||||
RUN bun run build
|
||||
|
||||
# Expose port
|
||||
EXPOSE 3001
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
"scripts": {
|
||||
"dev": "bun --hot server.ts",
|
||||
"start": "bun server.ts",
|
||||
"build": "bun build public/index.html --outdir ./dist --target browser"
|
||||
"build": "bun build src/main.tsx --outdir ./public/dist --target browser --minify"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/bun": "latest",
|
||||
|
||||
@@ -4,9 +4,10 @@
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>AiWorker - AI Agent Orchestration Platform</title>
|
||||
<link rel="stylesheet" href="/dist/main.css">
|
||||
</head>
|
||||
<body>
|
||||
<div id="root"></div>
|
||||
<script type="module" src="../src/main.tsx"></script>
|
||||
<script type="module" src="/dist/main.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
Reference in New Issue
Block a user