I’m trying to setup a showcase for Sensu in K8s cluster.
I followed de dose here Install Sensu - Sensu Docs
-
Create namespace : sensu-system
-
Created Deployment file
[]$ cat sensu-backend.yaml
apiVersion: apps/v1
kind: Deployment
metadata:
name: sensu-backend
spec:
selector:
matchLabels:
app: sensu-backend
replicas: 1
template:
metadata:
name: sensu-backend
labels:
app: sensu-backend
spec:
containers:
- name: sensu-backend
image: sensu/sensu:latest
command: ["/opt/sensu/bin/sensu-backend", "start", "--state-dir", "/var/lib/sensu/sensu-backend", "--log-level", "debug"]
ports:
- protocol: TCP
containerPort: 8080
- protocol: TCP
containerPort: 8081
- protocol: TCP
containerPort: 3000
---
apiVersion: v1
kind: Service
metadata:
name: sensu-backend
spec:
selector:
app: sensu-backend
type: NodePort
ports:
- name: api
protocol: TCP
port: 8080
targetPort: 8080
- name: ws
protocol: TCP
port: 8081
targetPort: 8081
- name: webui
protocol: TCP
port: 3000
targetPort: 3000
nodePort: 30030
- According to the docs I should skip initialization with a docker image.
The login screen appears when I go to port 30030, but the default user name password is not logging me in.
[]$ kubectl -n sensu-system get pods
NAME READY STATUS RESTARTS AGE
sensu-backend-54b7d67b69-hwc57 1/1 Running 0 88m
[]$ kubectl exec -n sensu-system --stdin --tty sensu-backend-54b7d67b69-hwc57 -- sh
/ # sensuctl configure -n --url http://127.0.0.1:8080 \
> --username admin \
> --password "P@ssw0rd!" \
> --namespace default
Error: unable to authenticate with error: Unauthorized
Same for namespace sensu-system …
Is this changed or do I forget something ??