73 lines
3.6 KiB
HTML
73 lines
3.6 KiB
HTML
{% extends "base.html" %}
|
|
{% block content %}
|
|
<div class="container my-5">
|
|
<div class="card shadow-sm">
|
|
<div class="card-header">
|
|
<h2 class="mb-0">Ustawienia globalne</h2>
|
|
</div>
|
|
<div class="card-body">
|
|
<form method="POST">
|
|
<!-- Sekcja Pushover -->
|
|
<div class="mb-4">
|
|
<h4 class="mb-3">Powiadomienia - Pushover</h4>
|
|
<div class="mb-3">
|
|
<label for="pushover_token" class="form-label">Pushover Token</label>
|
|
<input type="text" class="form-control" id="pushover_token" name="pushover_token" value="{{ settings.pushover_token }}">
|
|
</div>
|
|
<div class="mb-3">
|
|
<label for="pushover_userkey" class="form-label">Pushover User Key</label>
|
|
<input type="text" class="form-control" id="pushover_userkey" name="pushover_userkey" value="{{ settings.pushover_userkey }}">
|
|
</div>
|
|
<div class="form-check">
|
|
<input type="checkbox" class="form-check-input" id="notify_failures_only" name="notify_failures_only" value="True" {% if settings.notify_failures_only %}checked{% endif %}>
|
|
<label class="form-check-label" for="notify_failures_only">Wysyłaj powiadomienia tylko o błędach</label>
|
|
</div>
|
|
</div>
|
|
<hr>
|
|
<!-- Sekcja SMTP -->
|
|
<div class="mb-4">
|
|
<h4 class="mb-3">Powiadomienia - SMTP (e-mail)</h4>
|
|
<div class="mb-3 form-check">
|
|
<input type="checkbox" class="form-check-input" id="smtp_notifications_enabled" name="smtp_notifications_enabled" {% if settings.smtp_notifications_enabled %}checked{% endif %}>
|
|
<label class="form-check-label" for="smtp_notifications_enabled">Włącz powiadomienia SMTP</label>
|
|
</div>
|
|
<div class="mb-3">
|
|
<label for="smtp_host" class="form-label">SMTP Host</label>
|
|
<input type="text" class="form-control" id="smtp_host" name="smtp_host" value="{{ settings.smtp_host }}">
|
|
</div>
|
|
<div class="mb-3">
|
|
<label for="smtp_port" class="form-label">SMTP Port</label>
|
|
<input type="number" class="form-control" id="smtp_port" name="smtp_port" value="{{ settings.smtp_port }}">
|
|
</div>
|
|
<div class="mb-3">
|
|
<label for="smtp_login" class="form-label">SMTP Login / Adres</label>
|
|
<input type="text" class="form-control" id="smtp_login" name="smtp_login" value="{{ settings.smtp_login }}">
|
|
</div>
|
|
<div class="mb-3">
|
|
<label for="smtp_password" class="form-label">SMTP Hasło</label>
|
|
<input type="password" class="form-control" id="smtp_password" name="smtp_password" value="{{ settings.smtp_password }}">
|
|
</div>
|
|
</div>
|
|
<hr>
|
|
<!-- Sekcja globalnego klucza SSH -->
|
|
<div class="mb-4">
|
|
<h4 class="mb-3">Globalny klucz SSH</h4>
|
|
<div class="mb-3">
|
|
<label for="global_ssh_key" class="form-label">
|
|
Wklej wraz z <code>-----BEGIN RSA PRIVATE KEY-----</code> i <code>-----END RSA PRIVATE KEY-----</code>
|
|
</label>
|
|
<textarea class="form-control" id="global_ssh_key" name="global_ssh_key" rows="4">{{ settings.global_ssh_key }}</textarea>
|
|
</div>
|
|
</div>
|
|
<div class="d-grid">
|
|
<button type="submit" class="btn btn-primary btn-lg">Zapisz ustawienia</button>
|
|
</div>
|
|
</form>
|
|
</div>
|
|
<div class="card-footer text-center">
|
|
<p>Ustawienia dotyczące backupu oraz harmonogramu CRON znajdują się na <a href="{{ url_for('advanced_schedule') }}">zaawansowanych ustawieniach harmonogramu</a>.</p>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{% endblock %}
|