Fix: namespace-create have kubectl in path

pull/6/head
Konstantinos Tsakalozos 2017-07-03 18:22:20 +03:00
parent f38adf37de
commit cea934bcbc
1 changed files with 4 additions and 1 deletions

View File

@ -1,5 +1,5 @@
#!/usr/bin/env python3 #!/usr/bin/env python3
import os
from yaml import safe_load as load from yaml import safe_load as load
from charmhelpers.core.hookenv import ( from charmhelpers.core.hookenv import (
action_get, action_get,
@ -11,6 +11,9 @@ from charms.templating.jinja2 import render
from subprocess import check_output from subprocess import check_output
os.environ['PATH'] += os.pathsep + os.path.join(os.sep, 'snap', 'bin')
def kubectl(args): def kubectl(args):
cmd = ['kubectl'] + args cmd = ['kubectl'] + args
return check_output(cmd) return check_output(cmd)