Files
roa2web-service-auto/ssh-tunnel/Dockerfile
Marius Mutu 6b13ffa183 Initial commit: ROA2WEB - FastAPI + Vue.js + Telegram Bot
Modern ERP Reports Application with microservices architecture

Tech Stack:
- Backend: FastAPI + python-oracledb (Oracle DB integration)
- Frontend: Vue.js 3 + PrimeVue + Vite
- Telegram Bot: python-telegram-bot + SQLite
- Infrastructure: Shared database pool, JWT authentication, SSH tunnel

Features:
- FastAPI backend with async Oracle connection pool
- Vue.js 3 responsive frontend with PrimeVue components
- Telegram bot alternative interface
- Microservices architecture with shared components
- Complete deployment support (Linux Docker + Windows IIS)
- Comprehensive testing (Playwright E2E + pytest)

Repository Structure:
- reports-app/ - Main application (backend, frontend, telegram-bot)
- shared/ - Shared components (database pool, auth, utils)
- deployment/ - Deployment scripts (Linux & Windows)
- docs/ - Project documentation
- security/ - Security scanning and git hooks
2025-10-25 14:55:08 +03:00

40 lines
1.1 KiB
Docker

# SSH Tunnel Container for Oracle Database Connection
FROM alpine:3.18
# Install OpenSSH client and necessary tools
RUN apk add --no-cache \
openssh-client \
bash \
curl \
netcat-openbsd \
&& rm -rf /var/cache/apk/*
# Create non-root user
RUN addgroup -g 1001 -S tunnel && \
adduser -S -D -H -u 1001 -s /bin/bash -G tunnel tunnel
# Create SSH directory
RUN mkdir -p /home/tunnel/.ssh && \
chown -R tunnel:tunnel /home/tunnel
# Copy SSH key and set permissions (before switching to non-root user)
COPY ../secrets/roa_oracle_server /home/tunnel/.ssh/roa_oracle_server
RUN chown tunnel:tunnel /home/tunnel/.ssh/roa_oracle_server && \
chmod 600 /home/tunnel/.ssh/roa_oracle_server
# Copy SSH tunnel script
COPY ssh_tunnel_docker.sh /usr/local/bin/ssh_tunnel.sh
RUN chmod +x /usr/local/bin/ssh_tunnel.sh
# Switch to non-root user
USER tunnel
# Health check - verify tunnel is working
HEALTHCHECK --interval=30s --timeout=10s --start-period=15s --retries=3 \
CMD nc -z localhost 1521 || exit 1
# Expose the tunneled port
EXPOSE 1521
# Start SSH tunnel
ENTRYPOINT ["/usr/local/bin/ssh_tunnel.sh"]