Add --bind-conf flag for BIND domains.conf generation
Generate a BIND-format domains.conf file alongside catalog zones. New input properties: file= (zone data path) and dnssec (bare flag). When --bind-conf is set, every zone must have file= or it errors. Renames ZoneEntry.File to ZonesFile (input path for error messages) and adds ZoneFile (BIND file path) and DNSSEC (bool) fields.
This commit is contained in:
@@ -130,8 +130,8 @@ func TestGenerateCatalogZone(t *testing.T) {
|
||||
}
|
||||
|
||||
members := []ZoneEntry{
|
||||
{Zone: "b.example.com.", Catalogs: []string{"cat1"}, File: "test", Line: 1},
|
||||
{Zone: "a.example.com.", Catalogs: []string{"cat1"}, Group: "mygroup", File: "test", Line: 2},
|
||||
{Zone: "b.example.com.", Catalogs: []string{"cat1"}, ZonesFile: "test", Line: 1},
|
||||
{Zone: "a.example.com.", Catalogs: []string{"cat1"}, Group: "mygroup", ZonesFile: "test", Line: 2},
|
||||
}
|
||||
|
||||
content, err := generateCatalogZone("cat1", cfg, members, 2026030201)
|
||||
@@ -203,7 +203,7 @@ func TestGenerateCatalogZoneCOO(t *testing.T) {
|
||||
}
|
||||
|
||||
members := []ZoneEntry{
|
||||
{Zone: "a.example.com.", Catalogs: []string{"cat1"}, COO: "old.example.com.", File: "test", Line: 1},
|
||||
{Zone: "a.example.com.", Catalogs: []string{"cat1"}, COO: "old.example.com.", ZonesFile: "test", Line: 1},
|
||||
}
|
||||
|
||||
content, err := generateCatalogZone("cat1", cfg, members, 2026030201)
|
||||
|
||||
Reference in New Issue
Block a user