I'm trying to run a kubectl command from ansible.  

Basically the command will tell me if at least one pod is running from a deployment. 

```
kubectl get deploy sample-v1-deployment -o json -n sample | jq '.status.conditions[] | select(.reason == "MinimumReplicasAvailable") | .status' | tr -d '"'

```

I tried to run it from a playbook but I'm getting 

> 
> Unable to connect to the server: net/http: TLS handshake timeout
> 
> 
> 

This is my playbook:

```
- hosts: master
  gather_facts: no
  become: true

  tasks:
    - name: test command
      shell: kubectl get deploy sample-v1-deployment -o json -n sample | jq '.status.conditions[] | select(.reason == "MinimumReplicasAvailable") | .status' | tr -d '"'
      register: result

```

This is the output from ansible:

```
changed: [k8smaster01.test.com] => {
    "changed": true,
    "cmd": "kubectl get deploy sample-v1-deployment -o json -n sample | jq '.status.conditions[] | select(.reason == \"MinimumReplicasAvailable\") | .status' | tr -d '\"'",
    "delta": "0:00:10.507704",
    "end": "2019-04-02 20:59:17.882277",
    "invocation": {
        "module_args": {
            "_raw_params": "kubectl get deploy sample-v1-deployment -o json -n sample | jq '.status.conditions[] | select(.reason == \"MinimumReplicasAvailable\") | .status' | tr -d '\"'",
            "_uses_shell": true,
            "argv": null,
            "chdir": null,
            "creates": null,
            "executable": null,
            "removes": null,
            "stdin": null,
            "warn": true
        }
    },
    "rc": 0,
    "start": "2019-04-02 20:59:07.374573",
    "stderr": "Unable to connect to the server: net/http: TLS handshake timeout",
    "stderr_lines": [
        "Unable to connect to the server: net/http: TLS handshake timeout"
    ],
    "stdout": "",
    "stdout_lines": []
}

```

I can run the command manually on the master server without problems. I was also able to use k8s module to create different things on my kubernetes cluster.  

I know there is a kubectl module on ansible, could it be the problem?

Thanks