Archived
1.0.2 - fix network settings, permissions and branding
Wydanie WGTools-Extended / release (push) Successful in 14s
Wydanie WGTools-Extended / release (push) Successful in 14s
This commit is contained in:
1 parent
9c23169339
commit
aadc19341d
18 files changed
+241
-80
No files matched your search
+16
-27
@@ -1,5 +1,15 @@
|
||||
{% extends "base.html" %}
|
||||
{% block content %}
|
||||
{% macro network_binding_fields(prefix) %}
|
||||
<label><span>Nasłuchiwanie WireGuard</span><select id="{{ prefix }}-listen-mode"><option value="all">Wszystkie adresy i interfejsy</option><option value="address">Wybrany adres IPv4</option><option value="interface">Wybrany interfejs</option><option value="both">Adres IPv4 i interfejs</option></select><small>Port ustawisz w polu „Port nasłuchiwania”. Przy ograniczeniu dostęp przez IPv6 jest blokowany.</small></label>
|
||||
<label id="{{ prefix }}-listen-address-wrap" hidden><span>Adres IPv4 nasłuchiwania</span><input id="{{ prefix }}-listen-address" list="host-ip-options" placeholder="np. 203.0.113.10"></label>
|
||||
<label id="{{ prefix }}-listen-interface-wrap" hidden><span>Interfejs wejściowy</span><input id="{{ prefix }}-listen-interface" list="host-interface-options" placeholder="np. eth0"></label>
|
||||
<label><span>Ruch wychodzący (SNAT)</span><select id="{{ prefix }}-snat-mode"><option value="auto">Adres interfejsu wyjściowego (automatycznie)</option><option value="address">Wybrany główny adres IPv4</option></select></label>
|
||||
<label id="{{ prefix }}-snat-address-wrap" hidden><span>Główny adres IPv4</span><input id="{{ prefix }}-snat-address" list="host-ip-options" placeholder="np. 203.0.113.10"><small>Adres musi należeć do wybranego interfejsu wyjściowego.</small></label>
|
||||
<label><span>Adresy lub interfejsy do przekierowania portów</span><input id="{{ prefix }}-forward-sources" list="host-forward-options" placeholder="np. 203.0.113.10, eth1"><small>Wybierz lub wpisz adresy IPv4 albo nazwy interfejsów oddzielone przecinkami. Możesz użyć adresu SNAT.</small></label>
|
||||
{% endmacro %}
|
||||
<datalist id="host-ip-options"></datalist><datalist id="host-interface-options"></datalist><datalist id="host-forward-options"></datalist>
|
||||
|
||||
<section class="page-head page-head-actions">
|
||||
<div>
|
||||
<h1 data-i18n="server.title">{{ tr('server.title') }}</h1>
|
||||
@@ -11,30 +21,6 @@
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section class="card" id="extended-snat-card">
|
||||
<div class="card-head"><div><h2>Główny adres IPv4 dla ruchu wychodzącego</h2><p>Adres musi być przypisany do interfejsu wyjściowego serwera. Puste pole wyłącza regułę SNAT.</p></div></div>
|
||||
<form id="extended-snat-form" class="settings-form-pad">
|
||||
<div class="setup-grid">
|
||||
<label><span>Publiczny adres IPv4</span><input id="extended-snat-address" placeholder="203.0.113.10" maxlength="15"></label>
|
||||
<label><span>Interfejs wyjściowy</span><input id="extended-snat-uplink" placeholder="eth0" maxlength="15"></label>
|
||||
</div>
|
||||
<button class="btn primary" type="submit">Zapisz adres SNAT</button>
|
||||
<div id="extended-snat-status" class="operation-status" hidden></div>
|
||||
</form>
|
||||
</section>
|
||||
|
||||
<section class="card" id="extended-listen-card">
|
||||
<div class="card-head"><div><h2>Ograniczenie nasłuchiwania WireGuard</h2><p>Wybierz adres IPv4, interfejs wejściowy lub oba. Dla tego ograniczenia IPv6 zostanie zablokowane. Puste pola wyłączają ograniczenie.</p></div></div>
|
||||
<form id="extended-listen-form" class="settings-form-pad">
|
||||
<div class="setup-grid">
|
||||
<label><span>Adres IPv4</span><input id="extended-listen-address" placeholder="203.0.113.10" maxlength="15"></label>
|
||||
<label><span>Interfejs wejściowy</span><input id="extended-listen-interface" placeholder="eth0" maxlength="15"></label>
|
||||
</div>
|
||||
<button class="btn primary" type="submit">Zapisz ograniczenie</button>
|
||||
<div id="extended-listen-status" class="operation-status" hidden></div>
|
||||
</form>
|
||||
</section>
|
||||
|
||||
<section class="card">
|
||||
<div class="card-head"><div><h2>Grupy publicznych adresów IPv4</h2><p>Grupy przydzielają adresy do sieci. Ten sam adres może należeć do wielu grup.</p></div></div>
|
||||
<form id="extended-group-form" class="settings-form-pad">
|
||||
@@ -90,6 +76,7 @@
|
||||
<span data-i18n="server.listen_port">{{ tr('server.listen_port') }}</span>
|
||||
<input id="setup-port" type="number" min="1" max="65535" value="51820" required>
|
||||
</label>
|
||||
{{ network_binding_fields('setup') }}
|
||||
<label>
|
||||
<span data-i18n="interfaces.display_name">{{ tr('interfaces.display_name') }}</span>
|
||||
<input id="setup-display-name" maxlength="64" placeholder="Home">
|
||||
@@ -118,7 +105,7 @@
|
||||
<div class="setup-grid">
|
||||
<label>
|
||||
<span data-i18n="server.uplink">{{ tr('server.uplink') }}</span>
|
||||
<input id="setup-uplink" class="mono" placeholder="enp6s18" required>
|
||||
<input id="setup-uplink" list="host-interface-options" class="mono" placeholder="enp6s18" required>
|
||||
</label>
|
||||
<label>
|
||||
<span data-i18n="server.gateway">{{ tr('server.gateway') }}</span>
|
||||
@@ -491,6 +478,7 @@
|
||||
<input id="new-interface-port" type="number" min="1" max="65535" required>
|
||||
<small>{{ tr('interfaces.unique_port_hint') }}</small>
|
||||
</label>
|
||||
{{ network_binding_fields('new-interface') }}
|
||||
<label>
|
||||
<span>{{ tr('server.mtu') }}</span>
|
||||
<input id="new-interface-mtu" type="number" min="576" max="65535" placeholder="1420">
|
||||
@@ -498,7 +486,7 @@
|
||||
</label>
|
||||
<label>
|
||||
<span>{{ tr('server.uplink') }}</span>
|
||||
<input id="new-interface-uplink" class="mono" placeholder="enp6s18" required>
|
||||
<input id="new-interface-uplink" list="host-interface-options" class="mono" placeholder="enp6s18" required>
|
||||
</label>
|
||||
<label>
|
||||
<span>{{ tr('server.gateway') }}</span>
|
||||
@@ -555,6 +543,7 @@
|
||||
<span>{{ tr('server.listen_port') }}</span>
|
||||
<input id="server-edit-port" type="number" min="1" max="65535" required>
|
||||
</label>
|
||||
{{ network_binding_fields('server-edit') }}
|
||||
<label>
|
||||
<span>{{ tr('server.mtu') }}</span>
|
||||
<input id="server-edit-mtu" type="number" min="576" max="65535" placeholder="1420">
|
||||
@@ -577,7 +566,7 @@
|
||||
<div class="setup-grid">
|
||||
<label>
|
||||
<span>{{ tr('server.uplink') }}</span>
|
||||
<input id="server-edit-uplink" class="mono" placeholder="enp6s18" required>
|
||||
<input id="server-edit-uplink" list="host-interface-options" class="mono" placeholder="enp6s18" required>
|
||||
</label>
|
||||
<label>
|
||||
<span>{{ tr('server.local_network') }}</span>
|
||||
|
||||
@@ -232,7 +232,7 @@
|
||||
<div class="card-head">
|
||||
<div>
|
||||
<h2>{{ tr('settings.users') }}</h2>
|
||||
<p>{{ tr('settings.users_subtitle') }}</p>
|
||||
<p>{{ tr('settings.users_subtitle') }} Wybierz „Uprawnienia”, aby przydzielić użytkownikowi sieci i dozwolone działania.</p>
|
||||
</div>
|
||||
<button type="button" class="btn" id="add-user-button">{{ tr('settings.add_user') }}</button>
|
||||
</div>
|
||||
@@ -274,6 +274,18 @@
|
||||
</section>
|
||||
</div>
|
||||
|
||||
<div class="modal-backdrop" id="user-access-modal" hidden>
|
||||
<div class="modal-card" role="dialog" aria-modal="true" aria-labelledby="user-access-title">
|
||||
<div class="modal-head"><div><h2 id="user-access-title">Uprawnienia użytkownika</h2><p id="user-access-name"></p></div><button class="icon-btn" type="button" data-modal-close="user-access-modal" aria-label="Zamknij">×</button></div>
|
||||
<form id="user-access-form"><div class="modal-body">
|
||||
<input type="hidden" id="user-access-id">
|
||||
<label><span>Rola</span><select id="user-access-role"><option value="user">Użytkownik</option><option value="admin">Administrator</option></select></label>
|
||||
<p>Wybierz sieci i działania, które użytkownik może wykonywać w każdej z nich.</p>
|
||||
<div id="user-access-networks"></div><div id="user-access-status" class="operation-status" hidden></div>
|
||||
</div><div class="modal-actions"><button type="button" class="btn" data-modal-close="user-access-modal">Anuluj</button><button type="submit" class="btn primary">Zapisz uprawnienia</button></div></form>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="modal-backdrop" id="user-modal" hidden>
|
||||
<div class="modal-card user-modal" role="dialog" aria-modal="true" aria-labelledby="user-modal-title">
|
||||
<div class="modal-head">
|
||||
|
||||
Reference in new issue
Block a user