~springfield-team/charms/trusty/vem/next

« back to all changes in this revision

Viewing changes to hooks/config_changed.py

  • Committer: Shiva Prasad Rao
  • Date: 2014-12-19 18:52:31 UTC
  • Revision ID: shivrao@cisco.com-20141219185231-n1ymc5m0j7igfeg1
Addressing lint issues

Show diffs side-by-side

added added

removed removed

Lines of Context:
18
18
        temp = f.read()
19
19
        data = yaml.load(temp, Loader=yaml.loader.BaseLoader)
20
20
        if ((config('n1kv-source') != data["n1kv_conf"]["n1kv-source"]) or
21
 
            (config('n1kv-version') != data["n1kv_conf"]["n1kv-version"])):
 
21
                (config('n1kv-version') != data["n1kv_conf"]["n1kv-version"])):
22
22
            subprocess.call("hooks/install")
23
23
        data["n1kv_conf"]["n1kv-source"] = config('n1kv-source')
24
24
        data["n1kv_conf"]["n1kv-version"] = config('n1kv-version')
48
48
        subprocess.call(["sysctl", "-p", "/etc/sysctl.d/60-n1kv.conf"])
49
49
 
50
50
    common.update_n1kv_config()
51
 
    #Enable all required uplink on the host (ifconfig <interface> up)
 
51
    # Enable all required uplink on the host (ifconfig <interface> up)
52
52
    common.enable_uplink(data["n1kv_conf"]["uplink_profile"])
53
53
    common.enable_uplink(data["n1kv_conf"]["vtep_config"])
54
54