diff --git a/README.md b/README.md index 2385741..5696471 100644 --- a/README.md +++ b/README.md @@ -63,43 +63,19 @@ mockapi/ ## Installation -1. **Navigate to project directory**: +1. **Create project directory**: ```bash - cd ~/GitLab/customer-engineering/mockapi + sudo mkdir /opt/mockapi + sudo chown -R \$USER:\$USER /opt/mockapi + cd /opt/mockapi ``` - -2. **Create a virtual environment** (recommended): +2. **Clone Application**: ```bash - python3 -m venv venv - source venv/bin/activate # On Windows: venv\Scripts\activate + git clone https://git.sechpoint.app/customer-engineering/mockapi.git + chmod +x *.sh + ./install.sh ``` -3. **Install dependencies**: - ```bash - pip install -r requirements.txt - ``` - -4. **Configure environment variables**: - ```bash - cp example.env .env - # Edit .env with your settings (see example.env for all available variables) - ``` - - Minimal `.env` example: - ```ini - DATABASE_URL=sqlite+aiosqlite:///./mockapi.db - ADMIN_USERNAME=admin - ADMIN_PASSWORD=admin123 # Change this in production! - SECRET_KEY=your-secret-key-here # Change this! - DEBUG=True # Set to False in production - ``` - - The `example.env` file includes additional configuration options for OAuth2, logging, and server settings. - -5. **Initialize the database** (tables are created automatically on first run). - -**For production deployment**, consider using the automated `install.sh` script which handles virtual environment creation, dependency installation, secure credential generation, and systemd service setup. See [Production Deployment with install.sh](#production-deployment-with-installsh) for details. - ## Running the Application ### Development (with auto‑reload)