consul | highly available , and data center aware solution | Configuration Management library
kandi X-RAY | consul Summary
kandi X-RAY | consul Summary
Consul is a distributed, highly available, and data center aware solution to connect and configure applications across dynamic, distributed infrastructure.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of consul
consul Key Features
consul Examples and Code Snippets
Community Discussions
Trending Discussions on consul
QUESTION
I'm using consul, consul-template and nginx on docker. When adding each new service, i have to change consul-template source file again. By the way all we're using soap services and proxy. All of them have service uri. How can i write nginx.ctmpl ? example web service end point :
...ANSWER
Answered 2022-Mar-15 at 23:13This should do what you want.
Given the following service config:
QUESTION
I have a go app that i need to run multiple instances under separate subdomains, i have a working nomad consul setup and got the go app to run and is accessible via a fixed ip address and dedicated port. But i am stuck on how to make it work with the unique subdomains and working https.
So what i'm looking for is like app1 runs on https://app1.example.com app2 runs on https://app2.example.com I tried to use traefic (got it running as a job), DNSmasq but i havent got the above to work.
Any help would be much appriciated.
...ANSWER
Answered 2022-Feb-23 at 22:58Traefik supports integrating with Consul through its Consul Catalog provider. See https://learn.hashicorp.com/tutorials/nomad/load-balancing-traefik for an example of how to configure this when running Traefik on Nomad.
The example in that tutorial configures the tag traefik.http.routers.http.rule=Path('/myapp')
on the service so that requests for /myapp
are routed to the backend service instance. In your case, you'll need to modify this to match on the HTTP Host header so that you can route subdomains to different services. For example:
QUESTION
I have a spring boot application running in a Nomad cluster with Consul Connect enabled.
...ANSWER
Answered 2022-Feb-18 at 06:48Finally found it. Nomad has an option to expose a particular endpoint via sidecar proxy without mTLS authentication. The use case of this option is specifically for health check or metrics.
https://www.nomadproject.io/docs/job-specification/expose#expose-examples
The expose
stanza inside connect
stanza helps to achieve this.
QUESTION
I have read the similar question related to this problem. It ended up with frustration.
- I installed consul with docker. I run the following command.
docker run --name consul -d -p 8500:8500 consul
, then I tested if the registration of service works using postman PUT method, but didn't enable health check, the service register into consul successfully in the consul web UI. For now everything works as expected. - I have a local GRPC service written in go. The local service address is
127.0.0.1:8880
. The address of consul server is127.0.0.1:8500
. Then the service is registered into consul, but health check didn't work, getsAll service failing
. Then I tried following:
-
- Use local IP address which is
192.168.0.152:8500
as address of consul server and192.168.0.152:8880
as address of gprc service. Not working.
- Use local IP address which is
-
- Use local IP address which is
192.168.0.152:8500
as address of consul server and127.0.0.1:8880
as address of gprc service. Not working.
- Use local IP address which is
-
- Check if HTTP service works. There is a local web service written in GIN. The port is 1010. AgentServiceCheck is following. Tried method above. Not working.
ANSWER
Answered 2021-Nov-04 at 19:11Based on the documentation of the Consul API (https://www.consul.io/api-docs/agent/check#grpc), it seems that the GRPC
field that you're using
supports the standard gRPC health checking protocol.
Therefore, you only need to define the gRPC endpoint there, and the protocol will handle the health checks.
You can opt-out from this to use an HTTP endpoint for health checks by defining the HTTP
field in your Agent Service Check config. You can find more information about that in the documentation (https://www.consul.io/api-docs/agent/check#http)
QUESTION
Once I enabled encrypt
, all my consul cluster failed. this is sudo systemctl consul status
:
memberlist: failed to receive: No installed keys could decrypt
...ANSWER
Answered 2021-Nov-01 at 12:38You must have exactly the same encrypt
settings on both types of node: server and client. Or, you must have encryption disabled everywhere. You can consult the official tutorial of step-by-step enabling encryption on the existing cluster.
UPD: Some useful commands to use one key in all nodes (both client and server).
Get keys info from all nodes
QUESTION
I have a Micronaut 3 application, while using the JWT token the Authentication attribute on check method is null, however, I need to get all the roles from the JWT.
As per latest change from Micronaut
SecurityRule Changes
The SecurityRule API has changed. The last argument to the method was a map that represented the user attributes. Instead that argument was replaced with a reference to the Authentication. This has the benefit of rules now having access to the username of the logged in user as well as access to the convenience method getRoles().
...ANSWER
Answered 2021-Oct-22 at 15:58Add a breakpoint to JwtValidator
and increase the log level for security. Add the following line in logback.xml
:
QUESTION
I'm in the process of vetting a move to service mesh. While Istio
and Consul Connect
are certainly still in the cards, I'm leaning towards building up from a bit lower level with Linkerd
and SPIFFE/SPIRE
.
I want to build a 'hello world' mesh to test this architecture out. In this hello world mesh, I'd like to be able to issue certificates from SPIFFE/SPIRE
that encode some kind of role. As you can probably tell, I'm new to service meshes. How would I implement roles? Are there any guides out there to help get me started?
ANSWER
Answered 2021-Sep-23 at 16:25So there isn't any kind of integration with Linkerd and SPIFFE/SPIRE. As of right now there isn't any particular plan for an integration but you can see the existing issue for more details. The next release of Linkerd, 2.11, will include the ability to create server side policy but current versions don't enforce any kind of policy settings.
QUESTION
I have 2 different HashiCorp Consul clusters (lets call them cluster A and cluster B) running on different hosts.
My Python app is running on a host which I already installed on 1 client agent configured to cluster A and I want my app will be able to send requests to cluster B also (somehow distinguish between the 2 agents)
Is it possible to install a second client agent (configured to cluster B) on that same host? and if so, how it can be done? Will I just need to change to a different port? Can't find documentation for that use case.
Any possible solutions will be helpful, Thanks!
...ANSWER
Answered 2021-Sep-21 at 06:10Consul allows you to configure the ports for your agents so they don't conflict on a single host. I was able to do so in a file named:
QUESTION
I am trying to run consul in eks using helm. I ran below commands
helm repo add hashicorp https://helm.releases.hashicorp.com
kubectl create secret generic consul-gossip-encryption-key --from-literal=key=$(consul keygen) -n common
helm install consul hashicorp/consul --namespace common --set global.name=consul -f helm-consul-config.yaml --debug
It gives me below error
...ANSWER
Answered 2021-Sep-17 at 02:40You need to use a Helm chart that is compatible with the version of Consul you are installing. The last supported Helm chart version which is compatible with Consul 1.7.2 is version 0.21.0. See the compatibility matrix for Consul and Consul on Kubernetes at https://www.consul.io/docs/k8s/upgrade/compatibility for more info.
You should be able to successfully install Consul by using the following Helm install command.
QUESTION
For the below code of setting chromeoptions using addArguments() method is giving following error
...ANSWER
Answered 2021-Sep-07 at 14:31You miss the following dependency
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install consul
Standalone binary install: https://learn.hashicorp.com/tutorials/consul/get-started-install
Minikube install: https://learn.hashicorp.com/tutorials/consul/kubernetes-minikube
Kind install: https://learn.hashicorp.com/tutorials/consul/kubernetes-kind
Kubernetes install: https://learn.hashicorp.com/tutorials/consul/kubernetes-deployment-guide
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page