| Class | Symbiosis::Host |
| In: |
common/lib/symbiosis/host.rb
|
| Parent: | Object |
This class encompasses functions / data that are set host-wide.
| BYTEMARK_RANGES | = | %w(80.68.80.0/20 89.16.160.0/19 212.110.160.0/19 46.43.0.0/18 91.223.58.0/24 213.138.96.0/19 5.153.224.0/21 5.28.56.0/21 2001:41c8::/29).collect{|i| IPAddr.new(i)} |
| BACKUP_SPACE_FILENAME | = | "/etc/symbiosis/dns.d/backup.name" |
Returns an array of backup spaces name given the IP addresses of the machine. Returns an empty array if the argument is invalid, or if the argument is not a Bytemark IP. IPv6 capable.
Returns all IP addresses in use by a machine, in the order they were configured on the interfaces, as an array of IPAddr objects.
Returns all global IPv4 addresses in use by a machine, as an array of IPAddr objects.
Returns all global IPv6 addresses in use by a machine, as an array of IPAddr objects.
This returns the primary backup space. This is defined as the first in the list returned by backup_spaces OR whatever is contained in a file called /etc/symbiosis/dns.d/backup.name
Returns the primary interface for the machine as an Linux::Netlink::Link object.
We can define the primary interface as the one with the default route.
We match on scope == 0 (RT_SCOPE_UNIVERSE) and type == 1 (RTN_UNICAST) and gateway != nil