feat: add website package with Vite and Caddy

This commit is contained in:
Nathan Flurry 2026-01-25 04:05:12 -08:00
parent 4b483afbae
commit 924bacae4e
5 changed files with 49 additions and 0 deletions

View file

@ -0,0 +1,5 @@
:80 {
root * /srv
file_server
try_files {path} /index.html
}

View file

@ -0,0 +1,12 @@
FROM node:22-alpine AS build
WORKDIR /app
RUN npm install -g pnpm
COPY package.json pnpm-lock.yaml* ./
RUN pnpm install
COPY . .
RUN pnpm build
FROM caddy:alpine
COPY --from=build /app/dist /srv
COPY Caddyfile /etc/caddy/Caddyfile
EXPOSE 80

View file

@ -0,0 +1,10 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Sandbox Agent</title>
</head>
<body>
</body>
</html>

View file

@ -0,0 +1,15 @@
{
"name": "@sandbox-agent/website",
"private": true,
"version": "0.0.0",
"license": "Apache-2.0",
"type": "module",
"scripts": {
"dev": "vite",
"build": "vite build",
"preview": "vite preview"
},
"devDependencies": {
"vite": "^5.4.7"
}
}

View file

@ -0,0 +1,7 @@
import { defineConfig } from "vite";
export default defineConfig({
server: {
port: 3000
}
});