consul sync catalouge
- Dominant language
- Go
- Stars
- 30.1k
- Forks
- 4.6k
- Avg merge
- 2d 6h
- Merged PRs (30d)
- 43
Description
#### Overview of the Issue
Not able to sync services on consul ui
#### Reproduction Steps
Im running consul on kubernetes
kubernetes version: v1.17.4
consul version : 1.7.2
Im not using helm. Even I dont want to use helm.
I need to know how can I define following values in consul sts file??
syncCatalog:
enabled: true
```
root@k8m:/etc/ssl/test2# cat consul-1.yaml
apiVersion: apps/v1
kind: StatefulSet
metadata:
name: consul
namespace: kube-system
spec:
serviceName: consul
selector:
matchLabels:
app: consul
replicas: 3
template:
metadata:
labels:
app: consul
member: consul
spec:
securityContext:
fsGroup: 1000
containers:
- name: consul
image: "consul:1.7.2"
#image: "consul:0.9.3"
#image: "consul:0.9.1"
#image: "consul:1.4.0"
env:
- name: POD_IP
valueFrom:
fieldRef:
fieldPath: status.podIP
- name: GOSSIP_ENCRYPTION_KEY
valueFrom:
secretKeyRef:
name: consul
key: gossip-encryption-key
- name: NAMESPACE
valueFrom:
fieldRef:
fieldPath: metadata.namespace
args:
- "agent"
- "-ui"
- "-server"
- "-bootstrap-expect=3"
- "-bind=0.0.0.0"
- "-advertise=$(POD_IP)"
#- "-node=$(POD_IP)-0"
#- "-rpc-addr=consul-0.consul.$(NAMESPACE).svc.cluster.local:8400"
- "-retry-join=consul-0.consul.$(NAMESPACE).svc.cluster.local"
- "-retry-join=consul-1.consul.$(NAMESPACE).svc.cluster.local"
- "-retry-join=consul-2.consul.$(NAMESPACE).svc.cluster.local"
#- "-syncCatalog=true"
#- "-connectInject=true"
- "-client=0.0.0.0"
- "-data-dir=/consul/data"
- "-config-file=/consul/myconfig/server.json"
- "-datacenter=us-east-1"
- "-domain=cluster.local"
- "-disable-host-node-id"
- "-encrypt=$(GOSSIP_ENCRYPTION_KEY)"
- "-raft-protocol=3"
#- "-rejoin"
volumeMounts:
#- name: data
#mountPath: /consul/data
- name: config
mountPath: /consul/myconfig
- name: tls
mountPath: /etc/tls
lifecycle:
preStop:
exec:
command:
- /bin/sh
- -c
- consul leave
#- consul join
ports:
- containerPort: 8300
name: server
- containerPort: 8301
name: serflan-tcp
protocol: "TCP"
- containerPort: 8301
name: serflan-udp
protocol: "UDP"
- containerPort: 8302
name: serfwan-tcp
protocol: "TCP"
- containerPort: 8302
name: serfwan-udp
protocol: "UDP"
- containerPort: 8400
name: rpc-port
- containerPort: 8500
name: api-port
- containerPort: 8600
name: consuldns-tcp
protocol: "TCP"
- containerPort: 8600
name: consuldns-udp
protocol: "UDP"
volumes:
- name: config
configMap:
name: consul
- name: tls
secret:
secretName: consul
```
Contributor guide
Assessment
This issue has not been assessed yet.