PortForwardRow
Domain · ModemPort yönlendirme tablosu satırı. Kural adı, protokol, harici port, dahili IP:port ve etkin/devre dışı gösterimi.
| Name | Protocol | Ext Port | Internal |
|---|---|---|---|
|
HTTP Server
|
TCP | 80 | 192.168.1.10:8080 |
|
HTTPS Server
|
TCP | 443 | 192.168.1.10:8443 |
|
SSH Admin
|
TCP | 2222 | 192.168.1.10:22 |
|
Plex Media
|
TCP | 32400 | 192.168.1.11:32400 |
...
<% nat.portForwardRules.forEach(function(rule) { %>
<%- include('modules/domain/modem/PortForwardRow', { rule: rule }) %>
<% }); %>
| Name | Protocol | Ext Port | Internal |
|---|---|---|---|
|
Game Server
|
UDP | 27015–27030 | 192.168.1.10:27015–27030 |
<%- include('modules/domain/modem/PortForwardRow', {
rule: {
name: 'Game Server', enabled: true, protocol: 'UDP',
externalPort: { start: 27015, end: 27030 },
internalIp: '192.168.1.10',
internalPort: { start: 27015, end: 27030 },
}
}) %>
<%
var _rule = locals.rule || {};
var _enabled = _rule.enabled !== false;
function portStr(p) {
if (p === null || p === undefined) return '—';
if (typeof p === 'object' && p.start !== undefined) return p.start + '–' + p.end;
return String(p);
}
%>
<%= _rule.name %>
<% if (!_enabled) { %>
<% } %>
<%= portStr(_rule.externalPort) %>