Simplified: remove Tailwind, standalone static HTML
Some checks failed
Deploy to Easypanel / deploy (push) Has been cancelled

This commit is contained in:
Kunthawat Greethong
2026-04-28 10:18:57 +07:00
parent ad3bd39c2d
commit 18c4dbdb84
14 changed files with 97 additions and 362 deletions

View File

@@ -3,8 +3,8 @@ import { readFile } from 'node:fs/promises'
import { join, extname } from 'node:path'
import { existsSync } from 'node:fs'
const PORT = process.env.PORT || 8080
const DIST_DIR = process.env.DIST_DIR || './dist'
const PORT = process.env.PORT || 4321
const DIST_DIR = './dist'
const mimeTypes = {
'.html': 'text/html',
@@ -63,12 +63,10 @@ const server = createServer(async (req, res) => {
}
}
// 404
res.writeHead(404)
res.end('Not found')
})
server.listen(PORT, '0.0.0.0', () => {
console.log(`Server running at http://0.0.0.0:${PORT}`)
console.log(`Serving files from ${DIST_DIR}`)
})