Created
February 11, 2022 14:01
-
-
Save dgrstl/84ca94e3e40a33d4db4fd1ec02e29d29 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '3' | |
networks: | |
kong-net: | |
services: | |
# Kubernetes echo service, it just returns the requests it receives as responses | |
# This service will act as our upstream | |
http-echo: | |
image: gcr.io/kubernetes-e2e-test-images/echoserver:2.2 | |
networks: | |
- kong-net | |
ports: | |
- "8080:8080" | |
tcp-echo: | |
image: istio/tcp-echo-server:1.1 | |
networks: | |
- kong-net | |
ports: | |
- "9000:9000" | |
# Our zipkin server | |
zipkin: | |
image: openzipkin/zipkin:2 | |
networks: | |
- kong-net | |
ports: | |
- "9411:9411" | |
restart: on-failure | |
# Our Kong API gateway | |
# It expects a conf file in ./kong.yml for declarative configuration | |
kong: | |
image: kong/kong:2.1.0 | |
networks: | |
- kong-net | |
environment: | |
KONG_LOG_LEVEL: debug | |
KONG_ADMIN_ACCESS_LOG: /dev/stdout | |
KONG_ADMIN_ERROR_LOG: /dev/stderr | |
KONG_ADMIN_LISTEN: "0.0.0.0:8001" | |
KONG_STREAM_LISTEN: "0.0.0.0:8500" | |
KONG_DATABASE: "off" | |
KONG_DECLARATIVE_CONFIG: /usr/local/kong/pwd/kong.yml | |
KONG_PROXY_ACCESS_LOG: /dev/stdout | |
KONG_PROXY_ERROR_LOG: /dev/stderr | |
volumes: | |
- "$PWD:/usr/local/kong/pwd" | |
ports: | |
- "8000:8000/tcp" | |
- "8001:8001/tcp" | |
- "8500:8500/tcp" | |
- "8443:8443/tcp" | |
- "8444:8444/tcp" | |
depends_on: | |
- http-echo | |
- tcp-echo | |
- zipkin | |
healthcheck: | |
test: ["CMD", "kong", "health"] | |
interval: 10s | |
timeout: 10s | |
retries: 10 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment