Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chapter 14: First kubectl command fails #65

Open
rpjeff opened this issue May 11, 2023 · 1 comment
Open

Chapter 14: First kubectl command fails #65

rpjeff opened this issue May 11, 2023 · 1 comment

Comments

@rpjeff
Copy link

rpjeff commented May 11, 2023

The very first command after cd fails!

# kubectl apply -f prometheus/
namespace/kiamol-ch14-monitoring created
configmap/prometheus-config created
service/prometheus created
deployment.apps/prometheus created
serviceaccount/prometheus created
resource mapping not found for name: "prometheus" namespace: "" from "prometheus/prometheus.yaml": no matches for kind "ClusterRole" in version "rbac.authorization.k8s.io/v1beta1"
ensure CRDs are installed first
resource mapping not found for name: "prometheus" namespace: "" from "prometheus/prometheus.yaml": no matches for kind "ClusterRoleBinding" in version "rbac.authorization.k8s.io/v1beta1"
ensure CRDs are installed first

The kubernetes cluster is a simple single node k3s vanilla setup. kubectl is an alias for k3s kubectl

# k3s --version
k3s version v1.26.3+k3s1 (01ea3ff2)
go version go1.19.7

Possibly a change in the RBAC API?

@rpjeff
Copy link
Author

rpjeff commented May 11, 2023

Dropping the "beta1" off the end of "rbac.authorization.k8s.io/v1beta1" appears to work,

# kubectl apply -f prometheus/
namespace/kiamol-ch14-monitoring unchanged
configmap/prometheus-config unchanged
service/prometheus unchanged
deployment.apps/prometheus unchanged
serviceaccount/prometheus unchanged
clusterrole.rbac.authorization.k8s.io/prometheus created
clusterrolebinding.rbac.authorization.k8s.io/prometheus created

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant