All Projects → faizalpribadi → kongsul

faizalpribadi / kongsul

Licence: other
Kong Api Gateway with Consul Service Discovery (MicroService)

Programming Languages

shell
77523 projects

Projects that are alternatives of or similar to kongsul

Ansible Consul
📡 Ansible role for Hashicorp Consul clusters
Stars: ✭ 320 (+814.29%)
Mutual labels:  consul, service-discovery
Kong
🦍 The Cloud-Native API Gateway
Stars: ✭ 30,838 (+88008.57%)
Mutual labels:  consul, kong
Registrator
Service registry bridge for Docker with pluggable adapters
Stars: ✭ 4,558 (+12922.86%)
Mutual labels:  consul, service-discovery
superdiscoverer
A Supervisor backed service discoverer for automatic service-discovery.
Stars: ✭ 15 (-57.14%)
Mutual labels:  consul, service-discovery
User.api
集成网关、身份认证、Token授权、微服务、.netcore等的基于CQRS的微服务开发框架示例
Stars: ✭ 109 (+211.43%)
Mutual labels:  consul, service-discovery
Consul
Consul is a distributed, highly available, and data center aware solution to connect and configure applications across dynamic, distributed infrastructure.
Stars: ✭ 23,723 (+67680%)
Mutual labels:  consul, service-discovery
Spring Cloud Consul
Spring Cloud Consul
Stars: ✭ 703 (+1908.57%)
Mutual labels:  consul, service-discovery
rkt-compose
CLI to run Docker Compose file as pod on rkt with integrated service discovery using Consul - EOL
Stars: ✭ 24 (-31.43%)
Mutual labels:  consul, service-discovery
Eureka Consul Adapter
This project contains a Spring Boot Starter that registers HTTP endpoints on a Spring Cloud Eureka server to support Prometheus's service discovery mechanism for Consul (<consul_sd_config>)
Stars: ✭ 93 (+165.71%)
Mutual labels:  consul, service-discovery
Containerpilot
A service for autodiscovery and configuration of applications running in containers
Stars: ✭ 1,078 (+2980%)
Mutual labels:  consul, service-discovery
Consul.ServiceDiscovery.Demo
This demo shows how to implement simple containerized (Docker) microservice architecture with gateway, load balancer (Ocelot) and automatic service discovery (Consul).
Stars: ✭ 24 (-31.43%)
Mutual labels:  consul, service-discovery
Hippo
💨A well crafted go packages that help you build robust, reliable, maintainable microservices.
Stars: ✭ 134 (+282.86%)
Mutual labels:  consul, service-discovery
seagull
Configuration server submodule for all SeaSerives
Stars: ✭ 19 (-45.71%)
Mutual labels:  consul, service-discovery
Aspnet Servicediscovery Patterns
Samples of simple service discovery patterns with ASP .NET Core
Stars: ✭ 265 (+657.14%)
Mutual labels:  consul, service-discovery
consul-examples
Example usages of consul functionality.
Stars: ✭ 88 (+151.43%)
Mutual labels:  consul, service-discovery
Docker Alpine
Docker containers running Alpine Linux and s6 for process management. Solid, reliable containers.
Stars: ✭ 574 (+1540%)
Mutual labels:  consul, service-discovery
blogr-pve
Puppet provisioning of HA failover/cluster environment implemented in Proxmox Virtual Environment and Linux boxes.
Stars: ✭ 28 (-20%)
Mutual labels:  consul, service-discovery
hazelcast-consul-discovery-spi
Consul based discovery strategy SPI for Hazelcast enabled applications
Stars: ✭ 47 (+34.29%)
Mutual labels:  consul, service-discovery
Sample Vertx Microservices
Two applications in different branches illustrates how to create asynchronous microservices with Vert.x, Consul and MongoDB, and how to secure them with Vert.x OAuth2 module and Keycloak
Stars: ✭ 37 (+5.71%)
Mutual labels:  consul, service-discovery
Library
A microservice project using .NET Core 2.0, DDD, CQRS, Event Sourcing, Redis and RabbitMQ
Stars: ✭ 122 (+248.57%)
Mutual labels:  consul, service-discovery

KongSul

How to work Kong Api Gateway with Consul Service Discovery (MicroService)

Kong Introduction

see part of kong api gateway from official site kong-api

* how to register api on kong 

Consul Section

install consul and at the services.json, put the file into /etc/consul.d/services.json and you can run consule command like this:

$ consul agent -dev -config-dir=/etc/consul.d

By example, this is working on localhost, check you're consul ns is working correctly:

$ dig @127.0.0.1 -p 8600 go-svc-1.service.consul
$ dig @127.0.0.1 -p 8600 go-svc-1.service.consul SRV

; <<>> DiG 9.9.7-P3 <<>> @127.0.0.1 -p 8600 go-svc-1.service.consul SRV
; (1 server found)
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 26325
;; flags: qr aa rd; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 3
;; WARNING: recursion requested but not available

;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 4096
;; QUESTION SECTION:
;go-svc-1.service.consul.	IN	SRV

;; ANSWER SECTION:
go-svc-1.service.consul. 0	IN	SRV	1 1 8082 Faizals-MacBook-Pro.local.node.dc1.consul.

;; ADDITIONAL SECTION:
Faizals-MacBook-Pro.local.node.dc1.consul. 0 IN	A 127.0.0.1
Faizals-MacBook-Pro.local.node.dc1.consul. 0 IN	TXT "consul-network-segment="

;; Query time: 0 msec
;; SERVER: 127.0.0.1#8600(127.0.0.1)
;; WHEN: Wed Dec 27 22:51:37 WIB 2017
;; MSG SIZE  rcvd: 165

and check you're file at /etc/resolv.conf, register nameserver localhost like this:

$ nameserver 127.0.0.1

and you must set on kong.conf at line dns_resolver like this:

$ dns_resolver: 127.0.0.1:8600 // consul host & port 

and register the name of consul ns as upstream_url on kong api like this :

$ curl -i -X POST \
    --url http://localhost:8001/apis/ \
    --data 'name=your-api' \
    --data 'hosts=your-api.com' \
    --data 'upstream_url=http://go-svc-1.service.consul'

Testing Kong api and Consul Service Discovery Working Great Together:

$ curl -i -X GET \
    --url http://localhost:8000/ \
    --header 'Host: your-api.com'
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].