Public | Automated Build

Last pushed: 8 days ago
Short Description
Api router based on kong
Full Description

This Repository provides kong - an Api Router based on NGINX/OpenResty. Vicampo
uses kong to manage access to the different services. The Apis are configured
in kong and kong restricts access to these for each request. https://getkong.org/

Kong (the api router) is deployed as an ECS Service. It's Service and Taskdefinition
live in routes/wms/. The service connects to a Target Group of the
LoadBalancer, which is required if you want to load balance traffic to
an ecs service. See ecs_service.json file in wms/

.. note::

It was intended to have more than one router configuration in the routers/
folder. But as of now, there is only the need for one (wms).

Usage

In the folder kong/ lives the Dockerfile that creates the image that will be
run as ecs service. If you want to change the way kong works you will want to
change this image. E.g.: If you want to change configuration of either
nginx or kong itself see into kong/custom_nginx.template or
kong/config/kong.production.conf respectivly. After you have made your changes
you need to build and publish the image using

make kong-release

The resulting image is pushed to er (which is why you might need to login to
ecr first using the aws ecr login command.

After you have build the image you can deploy the new version using the
update-router.sh script. It requires a single paramter which is the name of
the folder in routers/ you want to update.

update-router.sh wms

That will deploy the task definition and inactivate all others of the same family.
It will also restart the service.

Resources

Bitbucket: https://bitbucket.org/vicampo/kong

Dockerhub: https://hub.docker.com/r/vicampo/kong/

Even more:

Docker Pull Command
Owner
vicampo
Source Repository