1 from charmhelpers
.core
.hookenv
import (
6 from charms
.reactive
import (
12 import charms
.sshproxy
15 @when_not('proxy-ci.installed')
16 def install_metrics_ci():
17 status_set('blocked', "Waiting for SSH credentials.")
18 set_flag('proxy-ci.installed')
21 @when('actions.test', 'proxy-ci.installed')
26 result
, err
= charms
.sshproxy
._run
(cmd
)
28 raise Exception("Proxy failed")
29 except Exception as e
:
30 action_fail('command failed: {}'.format(e
))
32 action_set({'output': result
})
34 clear_flag('actions.test')