bin/hva in wakame-vdc-agents-11.06.0 vs bin/hva in wakame-vdc-agents-11.12.0

- old
+ new

@@ -11,27 +11,37 @@ manifest = DEFAULT_MANIFEST.dup manifest.instance_eval do node_name 'hva' node_instance_id "#{Isono::Util.default_gw_ipaddr}" - load_module Isono::NodeModules::NodeHeartbeat - load_module Dcmgr::NodeModules::ServiceNetfilter - load_module Dcmgr::NodeModules::InstanceMonitor config do |c| c.vm_data_dir = '/var/lib/vm' + c.edge_networking = 'netfilter' c.enable_ebtables = true c.enable_iptables = true c.hv_ifindex = 2 # ex. /sys/class/net/eth0/ifindex => 2 - c.bridge_prefix = 'br' c.bridge_novlan = 'br0' c.verbose_netfilter = false c.packet_drop_log = false c.debug_iptables = false end load_config File.expand_path('config/hva.conf', app_root) + + load_module Isono::NodeModules::NodeHeartbeat + load_module Dcmgr::NodeModules::InstanceMonitor + case config.edge_networking + when 'openflow' + load_module Dcmgr::NodeModules::ServiceOpenFlow + when 'off' + # Don't load openflow nor netfilter + when 'netfilter', 'legacy_netfilter' + load_module Dcmgr::NodeModules::ServiceNetfilter + else + raise "Configuration error: '#{config.edge_networking}' is not a valid option for edge_networking. Valid options are 'openflow', 'netfilter', 'legacy_netfilter' and 'off'" + end end start(manifest) do - endpoint "kvm-handle.#{@node.node_id}", Dcmgr::Rpc::HvaHandler + endpoint "hva-handle.#{@node.node_id}", Dcmgr::Rpc::HvaHandler end