Skip to content

Commit

Permalink
Configures pykube to use the kubernetes config file path set in the j…
Browse files Browse the repository at this point in the history
…ob_conf.xml, imports Job instead of Pod.
  • Loading branch information
pcm32 committed Apr 6, 2016
1 parent f2ef8de commit 97af646
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions lib/galaxy/jobs/runners/kubernetes.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

from pykube.config import KubeConfig
from pykube.http import HTTPClient
from pykube.objects import Pod
from pykube.objects import Job
except ImportError as exc:
operator = None
K8S_IMPORT_MESSAGE = ('The Python pbs-python package is required to use '
Expand Down Expand Up @@ -44,8 +44,7 @@ def __init__( self, app, nworkers ):
# self.cli_interface = CliInterface()

# here we need to fetch the default kubeconfig path from the plugin defined in job_conf...
self._pykube_api = HTTPClient(KubeConfig.from_file(fromJobConfPluginParams))
# TODO how do we read from the config file the plugin parameters
self._pykube_api = HTTPClient(KubeConfig.from_file(self.runner_params["k8s_config_path"]))

# TODO do we need these?
# self._init_monitor_thread()
Expand Down

0 comments on commit 97af646

Please sign in to comment.