Class: KuberKit::Actions::KubectlAttacher
- Defined in:
- lib/kuber_kit/actions/kubectl_attacher.rb
Instance Method Summary collapse
Instance Method Details
#call(pod_name, options) ⇒ Object
9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 |
# File 'lib/kuber_kit/actions/kubectl_attacher.rb', line 9 def call(pod_name, ) kubeconfig_path = KuberKit.current_configuration.kubeconfig_path deploy_namespace = KuberKit.current_configuration.deploy_namespace kubectl_commands.exec( local_shell, pod_name, "bash", args: "-it", kubeconfig_path: kubeconfig_path, interactive: true, namespace: deploy_namespace ) true rescue KuberKit::Error => e ui.print_error("Error", e.) false end |