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

Docker deployment of services, can not modify the registered address of docker-consul #142

Open
xigang opened this issue Jun 25, 2016 · 0 comments

Comments

@xigang
Copy link

xigang commented Jun 25, 2016

After the start of the service, the consul.wath connection service is rejected.I don't know how to solve it:(

docker-compose.yml

sms:
    build: .
    environment:
        - MICRO_REGISTRY_ADDRESS=consul:8500
    volumes:
        - ./logs/:/sms/logs/
        - ./etc/env_strings.conf:/etc/env_strings.conf
    links:
        - consul
consul:
    command: -server -bootstrap -rejoin
    image: progrium/consul:latest

server log:

Creating sms_consul_1
Creating sms_sms_1
Attaching to sms_consul_1, sms_sms_1
consul_1  | ==> WARNING: Bootstrap mode enabled! Do not enable unless necessary
consul_1  | ==> WARNING: It is highly recommended to set GOMAXPROCS higher than 1
sms_1     | 2016/06/24 02:15:20 Listening on [::]:34066
consul_1  | ==> Starting raft data migration...
sms_1     | 2016/06/24 02:15:20 Broker Listening on [::]:46361
consul_1  | ==> Starting Consul agent...
sms_1     | 2016/06/24 02:15:20 Registering node: sms-7E67AC78
consul_1  | ==> Starting Consul agent RPC...
consul_1  | ==> Consul agent running!
consul_1  |          Node name: '6dd7183da9a7'
consul_1  |         Datacenter: 'dc1'
consul_1  |             Server: true (bootstrap: true)
consul_1  |        Client Addr: 0.0.0.0 (HTTP: 8500, HTTPS: -1, DNS: 53, RPC: 8400)
consul_1  |       Cluster Addr: 192.168.42.2 (LAN: 8301, WAN: 8302)
consul_1  |     Gossip encrypt: false, RPC-TLS: false, TLS-Incoming: false
consul_1  |              Atlas: <disabled>
consul_1  |
consul_1  | ==> Log data will now stream in as it occurs:
consul_1  |
consul_1  |     2016/06/24 02:15:20 [INFO] serf: EventMemberJoin: 6dd7183da9a7 192.168.42.2
consul_1  |     2016/06/24 02:15:20 [INFO] serf: EventMemberJoin: 6dd7183da9a7.dc1 192.168.42.2
consul_1  |     2016/06/24 02:15:20 [INFO] raft: Node at 192.168.42.2:8300 [Follower] entering Follower state
consul_1  |     2016/06/24 02:15:20 [INFO] consul: adding server 6dd7183da9a7 (Addr: 192.168.42.2:8300) (DC: dc1)
consul_1  |     2016/06/24 02:15:20 [INFO] consul: adding server 6dd7183da9a7.dc1 (Addr: 192.168.42.2:8300) (DC: dc1)
consul_1  |     2016/06/24 02:15:20 [ERR] agent: failed to sync remote state: No cluster leader
sms_1     | 2016/06/24 02:15:20 consul.watch: Watch (type: services) errored: Get http://127.0.0.1:8500/v1/catalog/services: dial tcp 127.0.0.1:8500: getsockopt: connection refused, retry in 5s
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