This document describes how to deploy the Radionica 3D platform to a production server.
The recommended production setup uses:
The frontend must be built as a set of static files.
# In project root
npm run build
This command:
dist/ directory.Ensure all production dependencies are installed and the environment variables are set in .env.production.
build_frontend.sh: Automates the frontend build process on the server. It handles atomic deployments by using symlinks (e.g., swapping a dist symlink to a new timestamped folder).server_update.sh: Pulls the latest code, builds the frontend, and restarts the backend services.The backend should run as a persistent service. Example configurations are provided in:
radionica-backend.service: Runs the FastAPI server via Uvicorn.radionica-deploy.service: A listener service for automated deployment triggers (if used).The nginx.conf file in the root is the source of truth for the web server configuration. Key features:
dist/public/./api/) and WebSockets (/ws/) to the FastAPI backend.index.html.backend/database.db is backed up regularly.backend/uploads/ directory must persist between deployments. Use a Docker volume or a dedicated persistent path.server_debug.log (if enabled) for backend issues.