duids = hosts_duids_pools[1],
pools = hosts_duids_pools[2],
networks = hosts_duids_pools[3],
- m, s, o, ss, so;
+ m, s, o, ss, so, dnss;
let noi18nstrings = {
etc_hosts: '<code>/etc/hosts</code>',
s.tab('general', _('General'));
s.tab('devices', _('Devices & Ports'));
+ s.tab('dnsrecords', _('DNS Records'));
s.tab('dnssecopt', _('DNSSEC'));
s.tab('filteropts', _('Filter'));
s.tab('forward', _('Forwards'));
s.tab('logging', _('Log'));
s.tab('files', _('Resolv & Hosts Files'));
s.tab('leases', _('Static Leases'));
- s.tab('hosts', _('Hostnames'));
s.tab('ipsets', _('IP Sets'));
s.tab('relay', _('Relay'));
- s.tab('srvhosts', _('SRV'));
- s.tab('mxhosts', _('MX'));
- s.tab('cnamehosts', _('CNAME'));
s.tab('pxe_tftp', _('PXE/TFTP'));
s.taboption('filteropts', form.Flag, 'domainneeded',
so.value(index, display_str);
});
- o = s.taboption('srvhosts', form.SectionValue, '__srvhosts__', form.TableSection, 'srvhost', null,
+ o = s.taboption('dnsrecords', form.SectionValue, '__dnsrecords__', form.TypedSection, '__dnsrecords__');
+
+ dnss = o.subsection;
+
+ dnss.anonymous = true;
+ dnss.cfgsections = function() { return [ '__dnsrecords__' ] };
+
+ dnss.tab('hosts', _('Hostnames'));
+ dnss.tab('srvhosts', _('SRV'));
+ dnss.tab('mxhosts', _('MX'));
+ dnss.tab('cnamehosts', _('CNAME'));
+
+ o = dnss.taboption('srvhosts', form.SectionValue, '__srvhosts__', form.TableSection, 'srvhost', null,
_('Bind service records to a domain name: specify the location of services. See <a href="%s">RFC2782</a>.').format('https://datatracker.ietf.org/doc/html/rfc2782')
+ '<br />' + _('_service: _sip, _ldap, _imap, _stun, _xmpp-client, … . (Note: while _http is possible, no browsers support SRV records.)')
+ '<br />' + _('_proto: _tcp, _udp, _sctp, _quic, … .')
so.datatype = 'range(0,65535)';
so.placeholder = '50';
- o = s.taboption('mxhosts', form.SectionValue, '__mxhosts__', form.TableSection, 'mxhost', null,
+ o = dnss.taboption('mxhosts', form.SectionValue, '__mxhosts__', form.TableSection, 'mxhost', null,
_('Bind service records to a domain name: specify the location of services.')
+ '<br />' + _('You may add multiple records for the same domain.'));
so.datatype = 'range(0,65535)';
so.placeholder = '0';
- o = s.taboption('cnamehosts', form.SectionValue, '__cname__', form.TableSection, 'cname', null,
+ o = dnss.taboption('cnamehosts', form.SectionValue, '__cname__', form.TableSection, 'cname', null,
_('Set an alias for a hostname.'));
ss = o.subsection;
so.datatype = 'hostname';
so.placeholder = 'example.com.';
- o = s.taboption('hosts', form.SectionValue, '__hosts__', form.GridSection, 'domain', null,
+ o = dnss.taboption('hosts', form.SectionValue, '__hosts__', form.GridSection, 'domain', null,
_('Hostnames are used to bind a domain name to an IP address. This setting is redundant for hostnames already configured with static leases, but it can be useful to rebind an FQDN.'));
ss = o.subsection;