Create consul service

26 views
Skip to first unread message

Quang Lê

unread,
May 22, 2020, 5:12:18 AM5/22/20
to Consul
Hi eveyone !

I'm using Consul for Service Discovery. I have: 1 Server + 1 client. 
I have created 1 service on Server but it not appeared in Client. How to auto create service on one Node and also appeare in all Node ( or some node by define) 

Thank for support !

Jono Sosulska

unread,
Jun 1, 2020, 1:15:32 PM6/1/20
to consu...@googlegroups.com
Hi Quang,

Thank you for your email. You may get more of a response through our Discuss forum, found here: https://discuss.hashicorp.com/c/consul/29.

As for your question - you will want your service to be registered with the client first, as the client forwards the catalog registration to the server. You can register a service on the server node, because a server has the client functionality. It is a better workflow to register your service with the agent local to the service, and not to run additional services on your server instances.  Please see our architecture docs which explain more about each role.

Best,
Jono Sosulska

Digital Developer Advocate || Community
jo...@hashicorp.com           || @Jono


--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/hashicorp/consul/issues
Community chat: https://gitter.im/hashicorp-consul/Lobby
---
You received this message because you are subscribed to the Google Groups "Consul" group.
To unsubscribe from this group and stop receiving emails from it, send an email to consul-tool...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/consul-tool/12e5789b-9bb6-453b-837e-443c4135a4e3%40googlegroups.com.

lng.qu...@gmail.com

unread,
Jun 2, 2020, 3:31:19 AM6/2/20
to consu...@googlegroups.com

Thank you for your reply

 

My ideal is:

 

In my example: I have 1 Cluster: 3 Server + 3 Agent.

I register 1 service (i.e: name:web, port:80) on 1 of 3 Node Agent. Then I want this service ( web) also available in other Node ( 2 agent + 3 Master)  without register service web on every node

How can I do that ?

 

Thank you !

Reply all
Reply to author
Forward
0 new messages