Changeset 2037 for trunk/packages/invirt-dns/invirt-dns
- Timestamp:
- Jan 30, 2009, 8:38:36 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/packages/invirt-dns/invirt-dns
r1974 r2037 8 8 from twisted.python import failure 9 9 10 from invirt.common import InvirtConfigError 10 11 from invirt.config import structs as config 11 12 import invirt.database … … 170 171 if '__main__' == __name__: 171 172 resolvers = [] 172 for zone in config.dns.zone_files: 173 for origin in config.dns.domains: 174 r = QuotingBindAuthority(zone) 175 # This sucks, but if I want a generic zone file, I have to 176 # reload the information by hand 177 r.origin = origin 178 lines = open(zone).readlines() 179 lines = r.collapseContinuations(r.stripComments(lines)) 180 r.parseLines(lines) 181 182 resolvers.append(r) 173 try: 174 for zone in config.dns.zone_files: 175 for origin in config.dns.domains: 176 r = QuotingBindAuthority(zone) 177 # This sucks, but if I want a generic zone file, I have to 178 # reload the information by hand 179 r.origin = origin 180 lines = open(zone).readlines() 181 lines = r.collapseContinuations(r.stripComments(lines)) 182 r.parseLines(lines) 183 184 resolvers.append(r) 185 except InvirtConfigError: 186 # Don't care if zone_files isn't defined 187 pass 183 188 resolvers.append(DatabaseAuthority()) 184 189
Note: See TracChangeset
for help on using the changeset viewer.