Я пытаюсь настроить свой сервер от комаров внутри кластера Kubernetes, и почему-то я получаю следующую ошибку, и я не могу понять, почему.Может ли кто-нибудь помочь мне?
Ошибка:
1551171948: mosquitto version 1.4.10 (build date Wed, 13 Feb 2019 00:45:38 +0000) starting
1551171948: Config loaded from /etc/mosquitto/mosquitto.conf.
1551171948: |-- *** auth-plug: startup
1551171948: |-- ** Configured order: http
1551171948: |-- with_tls=false
1551171948: |-- getuser_uri=/api/mosquitto/users
1551171948: |-- superuser_uri=/api/mosquitto/admins
1551171948: |-- aclcheck_uri=/api/mosquitto/permissions
1551171948: |-- getuser_params=(null)
1551171948: |-- superuser_params=(null)
1551171948: |-- aclcheck_paramsi=(null)
1551171948: Opening ipv4 listen socket on port 1883.
1551171948: Error: Cannot assign requested address
Mosquitto.conf:
allow_duplicate_messages false
connection_messages true
log_dest stdout stderr
log_timestamp true
log_type all
persistence false
listener 1883 mosquitto
allow_anonymous true
# Public
# listener 8883 0.0.0.0
listener 9001 0.0.0.0
protocol websockets
allow_anonymous false
auth_plugin /usr/lib/mosquitto-auth-plugin/auth-plugin.so
auth_opt_backends http
auth_opt_http_ip 127.0.0.1
auth_opt_http_getuser_uri /api/mosquitto/users
auth_opt_http_superuser_uri /api/mosquitto/admins
auth_opt_http_aclcheck_uri /api/mosquitto/permissions
auth_opt_acl_cacheseconds 1
auth_opt_auth_cacheseconds 0
Kubernetes.yaml:
apiVersion: apps/v1beta1
kind: Deployment
metadata:
name: mosquitto
spec:
replicas: 1
template:
metadata:
labels:
app: mosquitto
spec:
imagePullSecrets:
- name: abb-login
containers:
- name: mosquitto
image: ****mosquitto:develop
imagePullPolicy: Always
ports:
- containerPort: 9001
protocol: TCP
- containerPort: 1883
protocol: TCP
- containerPort: 8883
protocol: TCP
resources: {}
---
apiVersion: v1
kind: Service
metadata:
name: mosquitto
spec:
ports:
- name: "9001"
port: 9001
targetPort: 9001
protocol: TCP
- name: "1883"
port: 1883
targetPort: 1883
protocol: TCP
- name: "8883"
port: 8883
targetPort: 8883
protocol: TCP
selector:
app: mosquitto