44 lines
2.2 KiB
HTML
44 lines
2.2 KiB
HTML
{% extends "base.html" %}
|
|
{% block content %}
|
|
<div class="container mt-5">
|
|
<div class="card shadow-sm">
|
|
<div class="card-header">
|
|
<h2 class="mb-0">Edycja urządzenia</h2>
|
|
</div>
|
|
<div class="card-body">
|
|
<form method="POST">
|
|
<div class="mb-3">
|
|
<label for="name" class="form-label"><b>Nazwa</b></label>
|
|
<input type="text" class="form-control" id="name" name="name" value="{{ router.name }}" required>
|
|
</div>
|
|
<div class="mb-3">
|
|
<label for="host" class="form-label"><b>Host/IP</b></label>
|
|
<input type="text" class="form-control" id="host" name="host" value="{{ router.host }}" required>
|
|
</div>
|
|
<div class="mb-3">
|
|
<label for="port" class="form-label"><b>Port SSH</b></label>
|
|
<input type="number" class="form-control" id="port" name="port" value="{{ router.port }}" required>
|
|
</div>
|
|
<div class="mb-3">
|
|
<label for="ssh_user" class="form-label"><b>Użytkownik SSH</b></label>
|
|
<input type="text" class="form-control" id="ssh_user" name="ssh_user" value="{{ router.ssh_user }}">
|
|
</div>
|
|
<div class="mb-3">
|
|
<label for="ssh_key" class="form-label">
|
|
<label for="ssh_password" class="form-label"><b>Klucz prywatny</b></label> | Wklej wraz z <code>-----BEGIN RSA PRIVATE KEY-----</code> i <code>-----END RSA PRIVATE KEY-----</code><br>
|
|
Pozostaw puste jeśli ten RouterOS będzie używał <a href="{{ url_for('settings_view') }}">klucza globalnego</a>
|
|
</label>
|
|
<textarea class="form-control" id="ssh_key" name="ssh_key" rows="4">{{ router.ssh_key }}</textarea>
|
|
</div>
|
|
<div class="mb-3">
|
|
<label for="ssh_password" class="form-label"><b>Hasło SSH</b></label><br>
|
|
Jeśli podajesz klucz SSH lub zdefiniowany jest <a href="{{ url_for('settings_view') }}">klucz globalny</a>, to logowanie hasłem jest nieaktywne.
|
|
<input type="password" class="form-control" id="ssh_password" name="ssh_password" value="{{ router.ssh_password }}">
|
|
</div>
|
|
<button type="submit" class="btn btn-success">Zapisz zmiany</button>
|
|
</form>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{% endblock %}
|