Commit Graph

10 Commits (master)

Author SHA1 Message Date
Vitaliy Filippov 6de1109854 Change to a non-root user after starting the server 2020-01-17 17:22:19 +03:00
Justin Riley 1d7f8dcf63 catch and log all sync exceptions in daemon
...instead of crashing.
2017-04-14 14:14:57 -04:00
Justin Riley f71b8080cc daemon: sync with opennebula on defined interval
- Added --sync-interval option that defaults to 5 minutes
2016-10-21 00:30:39 -04:00
Justin Riley 9ca71db458 server: sanitize VM names in _get_vm_dns_entries
...using the same method as 15-hostname in OpenNebula/addon-context-linux
2016-10-06 00:23:40 -04:00
Justin Riley 4c245819ce server: implement tiebreaker for VMs with same name/IP
The tiebreaker is first-come first serve - ie whichever VM had the name
or IP first wins (based on VM id). The sync() method now sorts the VM
list by id in order to evaluate the tiebreaker correctly (VM list comes
that way from ONED but just in case...).
2016-09-28 11:18:14 -04:00
Justin Riley a7051e0689 server: build new zone and replace live copy in sync
Instead of clearing the live zone and iterating through and adding
records from OpenNebula we build an entirely new zone, sync it with
OpenNebula, and instantaneously swap it with the currently live zone.
This minimizes the amount of time that the DNS server is missing entries
while its syncing with OpenNebula.
2016-09-28 11:16:31 -04:00
Justin Riley 6fecaed95a add optional vms kwarg to sync for testing 2016-08-12 10:44:09 -04:00
Justin Riley fb1608ce56 move api.py module to server.py 2016-08-02 13:31:55 -04:00
Justin Riley 12a2a46f14 move server.py -> resolver.py 2016-08-02 12:39:02 -04:00
Justin Riley a80a85191c add DynamicResolver class with 100% test coverage 2016-08-02 11:29:16 -04:00