Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

luci-mod-network: dhcp tags improvements #6840

Closed
wants to merge 2 commits into from

Conversation

jjm2473
Copy link
Contributor

@jjm2473 jjm2473 commented Jan 18, 2024

  1. host tag add candidates
  2. add a tab for tags

Signed-off-by: Liangbin Lian <jjm2473@gmail.com>
Signed-off-by: Liangbin Lian <jjm2473@gmail.com>
_('Use tags to advertise different gateway and/or DNS to different hosts. Hosts can be associated with tags in "%s" tab').format(_('Static Leases')) + '<br />' +
_('DHCP Options') + ': ' + _('Define additional DHCP options, for example "<code>6,192.168.2.1,192.168.2.2</code>" which advertises different DNS servers to clients.') +
_('"<code>3,192.168.2.1</code>" which advertises different gateway to clients.') + '<br />' +
_('Note: Do not use "odhcpd" or network interface (such as "lan", "wan", "wan6", etc.) as name when adding tags, conflicts will occur. It is recommended to prefix the name with "t_" to avoid such conflicts.'));
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should add a section name validator to check for this. Iirc the generic logic will already ensure that a chosen section name is unique, in case it is not, we should add a validator.

Copy link
Contributor Author

@jjm2473 jjm2473 Jan 18, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have tested on 22.03, section name conflict occurs, sections with same name will be merged to a single section, the section type will be 'tag'

@systemcrash
Copy link
Contributor

Closing in favour of #7178 (which includes this functionality)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants