Files
digiserver-v2/app/templates/auth/register.html
Quality App Developer 48f1bfbcad Add HTTPS configuration management system
- Add HTTPSConfig model for managing HTTPS settings
- Add admin routes for HTTPS configuration management
- Add beautiful admin template for HTTPS configuration
- Add database migration for https_config table
- Add CLI utility for HTTPS management
- Add setup script for automated configuration
- Add Caddy configuration generator and manager
- Add comprehensive documentation (3 guides)
- Add HTTPS Configuration card to admin dashboard
- Implement input validation and security features
- Add admin-only access control with audit trail
- Add real-time configuration preview
- Integrate with existing Caddy reverse proxy

Features:
- Enable/disable HTTPS from web interface
- Configure domain, hostname, IP address, port
- Automatic SSL certificate management via Let's Encrypt
- Real-time Caddyfile generation and reload
- Full audit trail with admin username and timestamps
- Support for HTTPS and HTTP fallback access points
- Beautiful, mobile-responsive UI

Modified files:
- app/models/__init__.py (added HTTPSConfig import)
- app/blueprints/admin.py (added HTTPS routes)
- app/templates/admin/admin.html (added HTTPS card)
- docker-compose.yml (added Caddyfile mount and admin port)

New files:
- app/models/https_config.py
- app/blueprints/https_config.html
- app/utils/caddy_manager.py
- https_manager.py
- setup_https.sh
- migrations/add_https_config_table.py
- migrations/add_email_to_https_config.py
- HTTPS_STATUS.txt
- Documentation files (3 markdown guides)
2026-01-14 12:02:49 +02:00

28 lines
1.3 KiB
HTML
Executable File

{% extends "base.html" %}
{% block title %}Register - DigiServer v2{% endblock %}
{% block content %}
<div class="card" style="max-width: 400px; margin: 2rem auto;">
<h2>Register</h2>
<form method="POST" action="{{ url_for('auth.register') }}">
<div style="margin-bottom: 1rem;">
<label for="username" style="display: block; margin-bottom: 0.5rem;">Username</label>
<input type="text" id="username" name="username" required minlength="3"
style="width: 100%; padding: 0.5rem; border: 1px solid #ddd; border-radius: 4px;">
<small style="color: #7f8c8d;">Minimum 3 characters</small>
</div>
<div style="margin-bottom: 1rem;">
<label for="password" style="display: block; margin-bottom: 0.5rem;">Password</label>
<input type="password" id="password" name="password" required minlength="6"
style="width: 100%; padding: 0.5rem; border: 1px solid #ddd; border-radius: 4px;">
<small style="color: #7f8c8d;">Minimum 6 characters</small>
</div>
<button type="submit" class="btn btn-success" style="width: 100%;">Register</button>
</form>
<p style="margin-top: 1rem; text-align: center;">
Already have an account? <a href="{{ url_for('auth.login') }}">Login here</a>
</p>
</div>
{% endblock %}