Restructure chat service, web routes, and add test suite
Split monolithic chat service into modular structure with Matrix client support, extract web server into per-resource route modules, introduce bootstrap/main-loop separation, and add comprehensive vitest coverage across services, repositories, and utilities. Adds project docs and CLAUDE.md agent instructions.
This commit is contained in:
1 parent
dfa0580859
commit
633bb0ec04
84 files changed
+19278
-3888
No files matched your search
+26
-9
@@ -1,7 +1,17 @@
|
||||
# Use the official Playwright image which includes all browser dependencies
|
||||
FROM mcr.microsoft.com/playwright:v1.57.0-jammy
|
||||
|
||||
# Set working directory
|
||||
# Install Xvfb (virtual display), x11vnc (VNC server) and noVNC (web-based VNC client)
|
||||
# so a human can log in to Reddit through the dashboard.
|
||||
RUN apt-get update && apt-get install -y --no-install-recommends \
|
||||
xvfb \
|
||||
x11vnc \
|
||||
novnc \
|
||||
websockify \
|
||||
fluxbox \
|
||||
procps \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
# Copy package files
|
||||
@@ -16,15 +26,22 @@ COPY . .
|
||||
# Build the TypeScript project
|
||||
RUN npm run build
|
||||
|
||||
# Prune dev dependencies to reduce image size (optional, but good practice)
|
||||
# Note: we need to keep some deps if they are runtime requirements
|
||||
# npm prune --production
|
||||
|
||||
# Create data directory
|
||||
RUN mkdir -p data
|
||||
|
||||
# Expose the port defined in config (default 3000)
|
||||
EXPOSE 3000
|
||||
# Copy entrypoint
|
||||
COPY docker/entrypoint.sh /usr/local/bin/entrypoint.sh
|
||||
RUN chmod +x /usr/local/bin/entrypoint.sh
|
||||
|
||||
# Start the application using the compiled code
|
||||
CMD ["node", "dist/index.js"]
|
||||
# Web dashboard
|
||||
EXPOSE 3000
|
||||
# noVNC (browser-accessible VNC for human login)
|
||||
EXPOSE 6080
|
||||
|
||||
ENV DISPLAY=:99 \
|
||||
VNC_DISPLAY_NUM=99 \
|
||||
VNC_PORT=5900 \
|
||||
NOVNC_PORT=6080 \
|
||||
SCREEN_GEOMETRY=1280x800x24
|
||||
|
||||
CMD ["/usr/local/bin/entrypoint.sh"]
|
||||
Reference in new issue
Block a user