summaryrefslogtreecommitdiff
path: root/cloudinit/CloudConfig/cc_keys_to_console.py
diff options
context:
space:
mode:
Diffstat (limited to 'cloudinit/CloudConfig/cc_keys_to_console.py')
-rw-r--r--cloudinit/CloudConfig/cc_keys_to_console.py10
1 files changed, 6 insertions, 4 deletions
diff --git a/cloudinit/CloudConfig/cc_keys_to_console.py b/cloudinit/CloudConfig/cc_keys_to_console.py
index 08e8f085..d462a0a8 100644
--- a/cloudinit/CloudConfig/cc_keys_to_console.py
+++ b/cloudinit/CloudConfig/cc_keys_to_console.py
@@ -21,12 +21,14 @@ import subprocess
frequency = per_instance
-def handle(_name,cfg,_cloud,log,_args):
+def handle(_name, cfg, _cloud, log, _args):
cmd = [ '/usr/lib/cloud-init/write-ssh-key-fingerprints' ]
- fp_blacklist = util.get_cfg_option_list_or_str(cfg, "ssh_fp_console_blacklist", [])
- key_blacklist = util.get_cfg_option_list_or_str(cfg, "ssh_key_console_blacklist", ["ssh-dss"])
+ fp_blacklist = util.get_cfg_option_list_or_str(cfg,
+ "ssh_fp_console_blacklist", [])
+ key_blacklist = util.get_cfg_option_list_or_str(cfg,
+ "ssh_key_console_blacklist", ["ssh-dss"])
try:
- confp = open('/dev/console',"wb")
+ confp = open('/dev/console', "wb")
cmd.append(','.join(fp_blacklist))
cmd.append(','.join(key_blacklist))
subprocess.call(cmd, stdout=confp)