<p>I deployed prometheus and adapter.
I want to get custom metrics, but can't find resource</p>
<pre><code>$ kubectl get --raw /apis/custom.metrics.k8s.io/v1beta1
Error from server (NotFound): the server could not find the requested resource


$ kubectl get --raw /metrics
Error from server (NotFound): the server could not find the requested resource

$ kubectl get apiservice
NAME                                   SERVICE                            AVAILABLE   AGE
v1.                                    Local                              True        32d
v1.admissionregistration.k8s.io        Local                              True        32d
v1.apiextensions.k8s.io                Local                              True        32d
v1.apps                                Local                              True        32d
v1.authentication.k8s.io               Local                              True        32d
v1.authorization.k8s.io                Local                              True        32d
v1.autoscaling                         Local                              True        32d
v1.batch                               Local                              True        32d
v1.certificates.k8s.io                 Local                              True        32d
v1.coordination.k8s.io                 Local                              True        32d
v1.discovery.k8s.io                    Local                              True        32d
v1.events.k8s.io                       Local                              True        32d
v1.monitoring.coreos.com               Local                              True        3d17h
v1.networking.k8s.io                   Local                              True        32d
v1.node.k8s.io                         Local                              True        32d
v1.policy                              Local                              True        32d
v1.rbac.authorization.k8s.io           Local                              True        32d
v1.scheduling.k8s.io                   Local                              True        32d
v1.storage.k8s.io                      Local                              True        32d
v1alpha1.crd.k8s.amazonaws.com         Local                              True        32d
v1alpha1.kafka.strimzi.io              Local                              True        28d
v1alpha1.monitoring.coreos.com         Local                              True        3d17h
v1beta1.admissionregistration.k8s.io   Local                              True        32d
v1beta1.apiextensions.k8s.io           Local                              True        32d
v1beta1.authentication.k8s.io          Local                              True        32d
v1beta1.authorization.k8s.io           Local                              True        32d
v1beta1.batch                          Local                              True        32d
v1beta1.certificates.k8s.io            Local                              True        32d
v1beta1.coordination.k8s.io            Local                              True        32d
v1beta1.custom.metrics.k8s.io          monitoring/my-prometheus-adapter   True        17m
v1beta1.discovery.k8s.io               Local                              True        32d
v1beta1.events.k8s.io                  Local                              True        32d
v1beta1.extensions                     Local                              True        32d
v1beta1.flowcontrol.apiserver.k8s.io   Local                              True        32d
v1beta1.kafka.strimzi.io               Local                              True        28d
v1beta1.metrics.k8s.io                 kube-system/metrics-server         True        25d
v1beta1.networking.k8s.io              Local                              True        32d
v1beta1.node.k8s.io                    Local                              True        32d
v1beta1.policy                         Local                              True        32d
v1beta1.rbac.authorization.k8s.io      Local                              True        32d
v1beta1.scheduling.k8s.io              Local                              True        32d
v1beta1.storage.k8s.io                 Local                              True        32d
v1beta1.vpcresources.k8s.aws           Local                              True        32d
v1beta2.kafka.strimzi.io               Local                              True        28d
v2beta1.autoscaling                    Local                              True        32d
v2beta2.autoscaling                    Local                              True        32d
</code></pre>
<p>how can i get custom resource?</p>

zxc157
<p>This is EKS related <a href="https://github.com/kubernetes-sigs/metrics-server/issues/45" rel="nofollow noreferrer">known issue</a>.</p>
<p>To resolve it, you should <a href="https://github.com/kubernetes-sigs/metrics-server/issues/45#issuecomment-421345121" rel="nofollow noreferrer">update the kubernetes nodes security groups to allow ingress / incoming https connections from the EKS masters security group.</a></p>
<p>Please check below resolved github issues.</p>
<ul>
<li><a href="https://github.com/kubernetes-sigs/metrics-server/issues/45" rel="nofollow noreferrer">Metrics server api not getting registered #45</a></li>
<li><a href="https://github.com/kubernetes-sigs/metrics-server/issues/129" rel="nofollow noreferrer">[EKS] unable to fetch metrics from Kubelet #129</a></li>
<li><a href="https://github.com/awslabs/amazon-eks-ami/issues/55" rel="nofollow noreferrer">Metrics Server not working #55</a></li>
</ul>
