123 lines
		
	
	
		
			3.7 KiB
		
	
	
	
		
			HTML
		
	
	
	
	
	
			
		
		
	
	
			123 lines
		
	
	
		
			3.7 KiB
		
	
	
	
		
			HTML
		
	
	
	
	
	
<!DOCTYPE html>
 | 
						|
<html lang="en">
 | 
						|
<head>
 | 
						|
    <meta charset="UTF-8">
 | 
						|
    <title>Settings</title>
 | 
						|
    <style>
 | 
						|
        body { 
 | 
						|
            font-family: Arial, sans-serif; 
 | 
						|
            background: #f1f1f1; 
 | 
						|
            padding: 20px; 
 | 
						|
        }
 | 
						|
        .container { 
 | 
						|
            max-width: 500px; 
 | 
						|
            margin: 0 auto; 
 | 
						|
            background: #fff; 
 | 
						|
            padding: 20px; 
 | 
						|
            border-radius: 8px; 
 | 
						|
            box-shadow: 0 0 10px rgba(0,0,0,0.1); 
 | 
						|
        }
 | 
						|
        h1 { 
 | 
						|
            text-align: center; 
 | 
						|
            margin-bottom: 1em; 
 | 
						|
            color: #333;
 | 
						|
        }
 | 
						|
        label { 
 | 
						|
            display: block; 
 | 
						|
            margin-top: 1em; 
 | 
						|
            color: #555;
 | 
						|
        }
 | 
						|
        input[type="checkbox"] { 
 | 
						|
            margin-right: 5px; 
 | 
						|
        }
 | 
						|
        input[type="number"] { 
 | 
						|
            width: 100%; 
 | 
						|
            padding: 8px; 
 | 
						|
            margin-top: 4px; 
 | 
						|
            box-sizing: border-box; 
 | 
						|
            border: 1px solid #ccc; 
 | 
						|
            border-radius: 4px;
 | 
						|
        }
 | 
						|
        button { 
 | 
						|
            margin-top: 1em; 
 | 
						|
            padding: 10px 20px; 
 | 
						|
            background: #007bff; 
 | 
						|
            border: none; 
 | 
						|
            color: #fff; 
 | 
						|
            cursor: pointer; 
 | 
						|
            border-radius: 4px; 
 | 
						|
            font-size: 1em;
 | 
						|
            display: block; 
 | 
						|
            width: 100%;
 | 
						|
        }
 | 
						|
        button:hover { 
 | 
						|
            background: #0056b3; 
 | 
						|
        }
 | 
						|
        .links { 
 | 
						|
            text-align: center; 
 | 
						|
            margin-top: 10px; 
 | 
						|
        }
 | 
						|
        .links a { 
 | 
						|
            color: #007bff; 
 | 
						|
            text-decoration: none; 
 | 
						|
        }
 | 
						|
        .links a:hover { 
 | 
						|
            text-decoration: underline; 
 | 
						|
        }
 | 
						|
        .setting-group {
 | 
						|
            margin-bottom: 1em;
 | 
						|
        }
 | 
						|
        .setting-group span {
 | 
						|
            font-size: 0.9em;
 | 
						|
            color: #888;
 | 
						|
        }
 | 
						|
    </style>
 | 
						|
</head>
 | 
						|
<body>
 | 
						|
<div class="container">
 | 
						|
    <h1>Settings</h1>
 | 
						|
    <form method="POST" action="{{ url_for('settings') }}">
 | 
						|
        <div class="setting-group">
 | 
						|
            <label>
 | 
						|
                <input type="checkbox" name="auto_deploy" value="1" {% if settings.auto_deploy_enabled %}checked{% endif %}>
 | 
						|
                Enable Automatic Deployments
 | 
						|
            </label>
 | 
						|
        </div>
 | 
						|
        <div class="setting-group">
 | 
						|
            <label>
 | 
						|
                Deploy Interval (minutes):
 | 
						|
                <input type="number" name="deploy_interval" value="{{ settings.deploy_interval }}" min="1">
 | 
						|
                <span>Time between automatic deployments</span>
 | 
						|
            </label>
 | 
						|
        </div>
 | 
						|
        <div class="setting-group">
 | 
						|
            <label>
 | 
						|
                Automatic Backup Interval (minutes):
 | 
						|
                <input type="number" name="backup_interval" value="{{ settings.backup_interval }}" min="1">
 | 
						|
                <span>Set interval for automatic backups</span>
 | 
						|
            </label>
 | 
						|
        </div>
 | 
						|
        <div class="setting-group">
 | 
						|
            <label>
 | 
						|
                Backup Retention (days):
 | 
						|
                <input type="number" name="backup_retention_days" value="{{ settings.backup_retention_days or 0 }}" min="0">
 | 
						|
                <span>Older backups will be automatically removed</span>
 | 
						|
            </label>
 | 
						|
        </div>
 | 
						|
        <div class="setting-group">
 | 
						|
            <label>
 | 
						|
                <input type="checkbox" name="enable_regex_entries" value="1"
 | 
						|
                       {% if settings.regex_deploy_enabled %}checked{% endif %}>
 | 
						|
                Enable Regex/CIDR Entries
 | 
						|
            </label>
 | 
						|
            <span>Include CIDR-based entries in final /etc/hosts deploy</span>
 | 
						|
        </div>        
 | 
						|
        <button type="submit">Save Settings</button>
 | 
						|
    </form>
 | 
						|
    <div class="links">
 | 
						|
        <a href="{{ url_for('dashboard') }}">Back to Dashboard</a>
 | 
						|
    </div>
 | 
						|
</div>
 | 
						|
</body>
 | 
						|
</html>
 |