Home
Help
Search
Login
Register
OPNsense Forum
»
English Forums
»
General Discussion
»
Unbound: Bulk add host-entries (overrides)
« previous
next »
Print
Pages: [
1
]
Author
Topic: Unbound: Bulk add host-entries (overrides) (Read 2176 times)
nykaer
Newbie
Posts: 11
Karma: 0
Unbound: Bulk add host-entries (overrides)
«
on:
April 23, 2021, 04:48:21 pm »
I have quite a few host overrides I need to enter into our OPNsense.
Looked at the API, and I does not include these entries. I could manually enter them into /var/unbound/cat host_entries.conf. But according to docs, that will not survive a reboot.
Any ideas, before I spends hours "cURL'ing my way out of the problem??
/Nykaer
Logged
Patrick M. Hausen
Hero Member
Posts: 6803
Karma: 572
Re: Unbound: Bulk add host-entries (overrides)
«
Reply #1 on:
April 23, 2021, 05:24:25 pm »
Download a configuration (System --> Configuration --> Backups), examine the XML file you get. Populate the XML with your entries, restore config in the UI.
I did that for BIND zone entries, not difficult to script. If you are seriously pondering using curl, it shouldn't be difficult for you.
Logged
Deciso DEC750
People who think they know everything are a great annoyance to those of us who do.
(Isaac Asimov)
nykaer
Newbie
Posts: 11
Karma: 0
Re: Unbound: Bulk add host-entries (overrides)
«
Reply #2 on:
April 23, 2021, 06:13:39 pm »
That would work just fine.. Sold.
Thank you for the solution.
Logged
Print
Pages: [
1
]
« previous
next »
OPNsense Forum
»
English Forums
»
General Discussion
»
Unbound: Bulk add host-entries (overrides)