summaryrefslogtreecommitdiff
path: root/cloudinit/config/cc_phone_home.py
diff options
context:
space:
mode:
authorJoshua Harlow <harlowja@yahoo-inc.com>2012-11-07 10:42:54 -0500
committerScott Moser <smoser@ubuntu.com>2012-11-07 10:42:54 -0500
commit21a3cf3186809f9dae387e52e8bd9bc548981003 (patch)
treed82d3c05e0f295ad2dda2dee5d0ca5b6ab116b78 /cloudinit/config/cc_phone_home.py
parente6d4b76e5e60ff558c247ad76acd27343afe367c (diff)
parent8b677bc80a39a0eb1a3cc7989c6bffb959fc7a69 (diff)
downloadvyos-cloud-init-21a3cf3186809f9dae387e52e8bd9bc548981003.tar.gz
vyos-cloud-init-21a3cf3186809f9dae387e52e8bd9bc548981003.zip
test and path cleanups.
1. Remove the usage of the path.join function now that all code should be going through the util file methods (and they can be mocked out as needed). 2. Adjust all occurences of the above join function to either not use it or replace it with the standard os.path.join (which can also be mocked out as needed) 3. Fix pylint from complaining about the tests folder 'helpers.py' not being found. 4. Add a pylintrc file that is used instead of the options hidden in the 'run_pylint' tool.
Diffstat (limited to 'cloudinit/config/cc_phone_home.py')
-rw-r--r--cloudinit/config/cc_phone_home.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/cloudinit/config/cc_phone_home.py b/cloudinit/config/cc_phone_home.py
index ae1349eb..886487f8 100644
--- a/cloudinit/config/cc_phone_home.py
+++ b/cloudinit/config/cc_phone_home.py
@@ -84,10 +84,10 @@ def handle(name, cfg, cloud, log, args):
for (n, path) in pubkeys.iteritems():
try:
- all_keys[n] = util.load_file(cloud.paths.join(True, path))
+ all_keys[n] = util.load_file(path)
except:
util.logexc(log, ("%s: failed to open, can not"
- " phone home that data"), path)
+ " phone home that data!"), path)
submit_keys = {}
for k in post_list: