feat: replace browser login with imported Reddit sessions
This commit is contained in:
1 parent
2b0545afcf
commit
c483c7b8be
76 files changed
+2048
-2828
No files matched your search
+1
-46
@@ -1,58 +1,13 @@
|
||||
# Use the official Playwright image which includes all browser dependencies
|
||||
FROM mcr.microsoft.com/playwright:v1.57.0-jammy
|
||||
|
||||
# Install Xvfb (virtual display), x11vnc (VNC server) and noVNC (web-based VNC client)
|
||||
# so a human can log in to Reddit through the dashboard.
|
||||
ENV DEBIAN_FRONTEND=noninteractive \
|
||||
TZ=Etc/UTC
|
||||
RUN apt-get update && apt-get install -y --no-install-recommends \
|
||||
tzdata \
|
||||
xvfb \
|
||||
x11vnc \
|
||||
x11-utils \
|
||||
novnc \
|
||||
websockify \
|
||||
fluxbox \
|
||||
procps \
|
||||
ca-certificates \
|
||||
curl \
|
||||
&& curl -fsSLo /tmp/google-chrome-stable_current_amd64.deb \
|
||||
https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb \
|
||||
&& apt-get install -y --no-install-recommends \
|
||||
/tmp/google-chrome-stable_current_amd64.deb \
|
||||
&& rm -f /tmp/google-chrome-stable_current_amd64.deb \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
# Copy package files
|
||||
COPY package*.json ./
|
||||
|
||||
# Install dependencies (including devDependencies for building)
|
||||
RUN npm ci
|
||||
|
||||
# Copy source code
|
||||
COPY . .
|
||||
|
||||
# Build the TypeScript project
|
||||
RUN npm run build
|
||||
|
||||
# Create data directory
|
||||
RUN mkdir -p data
|
||||
|
||||
# Copy entrypoint
|
||||
COPY docker/entrypoint.sh /usr/local/bin/entrypoint.sh
|
||||
RUN chmod +x /usr/local/bin/entrypoint.sh
|
||||
|
||||
# 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"]
|
||||
CMD ["node", "dist/index.js"]
|
||||
Reference in new issue
Block a user