mirror of
https://github.com/geoffsee/open-gsio.git
synced 2025-09-08 22:56:46 +00:00
Add Docker support with Dockerfile
and docker-compose.yml
, update build scripts and README for containerized deployment.
- Updated server `Bun.build` configuration: adjusted `outdir`, added `format` as `esm`, and set `@open-gsio/client` to external. - Expanded README with Docker instructions. - Added new package `@open-gsio/analytics-worker`. - Upgraded dependencies (`vite`, `typescript`, `bun`) and locked `pnpm` version in `package.json`.
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
"type": "module",
|
||||
"scripts": {
|
||||
"dev": "bun src/server/server.ts",
|
||||
"build": "bun run src/server/build.ts"
|
||||
"build": "bun ./src/server/build.ts"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@open-gsio/env": "workspace:*",
|
||||
@@ -24,8 +24,11 @@
|
||||
"mobx-state-tree": "^6.0.1",
|
||||
"moo": "^0.5.2",
|
||||
"typescript": "^5.7.2",
|
||||
"vike": "0.4.193",
|
||||
"vike": "0.4.235",
|
||||
"vite": "^7.0.0",
|
||||
"zod": "^3.23.8",
|
||||
"dotenv": "^16.5.0"
|
||||
"dotenv": "^16.5.0",
|
||||
"bun": "^1.2.17",
|
||||
"@types/bun": "^1.2.17"
|
||||
}
|
||||
}
|
||||
|
@@ -1,9 +1,10 @@
|
||||
// handles builds the server into js
|
||||
await Bun.build({
|
||||
entrypoints: ['./server.ts'],
|
||||
outdir: '../dist',
|
||||
entrypoints: [import.meta.dir + '/server.ts'],
|
||||
outdir: './dist', // Changed from '../dist' to './dist'
|
||||
minify: true,
|
||||
target: 'node',
|
||||
splitting: true,
|
||||
format: 'esm', // Explicitly set ESM format
|
||||
throw: true,
|
||||
external: ['@open-gsio/client'], // Mark client as external to avoid bundling issues
|
||||
});
|
||||
|
@@ -4,9 +4,12 @@ import { configDefaults } from 'vitest/config';
|
||||
|
||||
export default defineConfig(({ command }) => {
|
||||
return {
|
||||
build: {
|
||||
cssMinify: 'esbuild',
|
||||
},
|
||||
test: {
|
||||
globals: true,
|
||||
environment: 'jsdom',
|
||||
environment: 'node',
|
||||
registerNodeLoader: false,
|
||||
// setupFiles: ['./src/test/setup.ts'],
|
||||
exclude: [...configDefaults.exclude, 'dist/**', '.open-gsio/**'],
|
||||
|
Reference in New Issue
Block a user