Node Proxy - 404 page not found

3/14/2018

I am trying to use node proxy API by using API call http://{endpoint:port}/api/v1/proxy/nodes/{name} but I am getting "404 page not found" when I pass a valid node name on all verbs (GET, POST, PUT, DELETE, OPTION, PATCH) except HEAD, and when invalid node name passed in parameter it returns a proper kubernetes object.

{
    "kind": "Status",
    "apiVersion": "v1",
    "metadata": {},
    "status": "Failure",
    "message": "nodes \"kube-master1\" not found",
    "reason": "NotFound",
    "details": {
        "name": "kube-master1",
        "kind": "nodes"
    },
    "code": 404
}

It look like kubernetes is trying to access any service which is not properly configured. any idea which service I need to configure to make it run.

Thanks,

-- Muhammad Tahir Hassan
kubernetes
proxy

1 Answer

3/14/2018

The problem is likely because you need to specify the port on the node to connect to. Depending on what you are trying to do you can try the following endpoints to check that the proxy is working correctly:

You can encrypt the connections from the apiserver to the node by prefixing https: to the node name.

Go here for further details related specifically to accessing Services via the apiserver proxy.

-- dippynark
Source: StackOverflow