Deploy Kong Api Management using Azure Resource Manager

 

I’m currently searching for a Api Management Solution & I’ve found Kong. Kong is built on top of reliable technologies like NGINX and Apache Cassandra, and provides you with an easy to use RESTful API to operate and configure the system. It was developed by The Mashape Team and used internally. Then they decided to propose this solution on GitHub as an Open-Source Api Management.

Kong is scalable, modular (with plugin development) and can run on any infrastructure.

At this time the Azure Deployment was not provided so I decided to create a Azure Resource Template to deploy an Test Environment of Kong with one Linux Ubuntu Server and a local installation of Kong & Cassandra on this server. (A standard A2 virtual Machine, 2 core, 3,5 Go RAM)

The Azure Resource Manager provide a way to deploy, manage and monitor Azure Resource in a Logical Resource Group. You can use template to deploy a large number of assets using the ARM. (more info on the Microsoft Azure Web Site)

Ready !

Starting the Environment

be sure you’ve an azure subscription before continue, you can try for free. And the Windows Azure Powershell  with Azure Resource Manager Commandlets.

Then clone the following Git Hub Repository :

$ git clone https://github.com/jdevillard/kong-azure

In this repository, you will have :

  • azuredeploy.json : the azure template file
  • azuredeploy.parameters.json : the azure template parameter file in which we’ll put value regarding our environment
  • kongscript.sh : this script will install the necessary software arount kong (JAVA, Cassandra etc…)
  • deploy.ps1 : powershell script to deploy the azure template.

With all of this, you need to customize :

  • azuredeploy.parameters.json with :
    • an Azure Storage Account
    • a Admin User Name (used to ssh to the Linux)
    • an SSH Key : you can follow this tutorial if necessary
    • dns Name for the public Ip to reach the Kong Gateway
    • the os of ubuntu (don’t change for latest version supported in azure)
    • the location of the Virtual Machine
    • the name of the Network Security Group (don’t change if you don’t know what it is)

 

  • deploy.ps1  with :
    • $resourceGroupName : the name of the new resource group where you want to create the Kong Virtual Machine
    • $subscriptionId : the id of your Azure Subscription to deploy the resource group.

 

Then you can place your prompt in the script directory and execute the deploy.ps1 script.

The script will ask you your Microsoft Account that allow you to access to your Azure Subscription.

After few minutes, you will have all you assets deployed in a single virtual machine on Microsoft Azure.

image

 

This template deploy :

  • a new Storage Account
  • an Azure Virtual Network
  • a Network Security Group in this network
  • a virtual machine
  • a network interface to allow communication between the virtual machine inside the network and internet
  • a public IP with an DNS
  • The port 8000 (for proxy) and 8001 (for admin) are opened in the VNET (and also the 22 for the SSH).

    Once it is deploy, you can test using Fiddler or Curl with the following url :

    curl GET http://<DNS>.<Location>.cloudpapp.azure.com:8001

    for me (with default value) :

    curl GET http://kongtemplate1.westeurope.cloudapp.azure.com:8001

    you will have the default response with the plugin available on the Gateway :

     

    This Virtual Machine is good to test the Kong Gateway on a single instance.

    I will see in the futur if I can deploy a cluster of Kong with Cassandra cluster for the configuration repository.

    Hope This Help!

    Posted in Azure, English, Microsoft | Tagged , , | 1 Comment

    WebCast Windows 10 IT Pro

     

    Le 13 octobre sera délivré en français un webcast live par 2 MVP, Nicolas Bonnet et Jean-Sébastien Duchêne.

    https://mvp.eventbuilder.com/event?eventid=c8r8x9

    Voici quelques infos sur le web cast :

    A propos

    Les équipes du programme MVP et Windows IT Pro sont heureuses de vous proposer un webcast live *gratuit*, faisant partie d’une initiative communautaire globale, afin de délivrer une première série de conseils à propos de Windows 10 Entreprise à destination des IT Pros. Ces webcasts sont délivrés par des MVP Microsoft issus des différents pays participants. Windows 10 IT Pro Readiness est une opportunité intéressante pour vous afin de découvrir les dernières fonctionnalités de Windows 10 Entreprise, et aussi pour entrer en contact avec les meilleurs experts MVP Windows.  

    N’hésitez pas à vous inscrire !

    Bon webcast

    Posted in Français, Microsoft | Tagged , , | Leave a comment

    Retour de vacances

    Allez c’est reparti, les vacances de cet été furent bonnes et bien rempli ! (un nouvel arrivant dans la famille) , maintenant il est temps de recommencer sérieusement à écrire quelques blogs post !

    Bonne rentrée à tous

    Posted in Non classé | Leave a comment

    Lancement de Visual Studio 2015 RTM

     

    A l’occasion du lancement de la version RTM du nouveau Visual Studio 2015, Microsoft Corp organise un évènement en ligne le 20 Juillet sur Channel 9: “Final Release Event”

    Voici les différents liens disponibles :

    Bonne séance !

    Posted in Français, Microsoft | Tagged , | Leave a comment

    MVP Award Renewal 2015: Microsoft Azure

    I’m very proud to be renewed for the 4 years in a row as an Microsoft Most Valuable Professional.

    This year, I’m changing my expertise from Microsoft Integration to Microsoft Azure.

    image

    Posted in English | Tagged , , | Leave a comment

    Microsoft Specialist : Developing Microsoft #Azure Solutions

     

    The last month, I’ve scheduled a Microsoft Certification in a Prometric Center. The certification was on Microsoft Azure Solution :

    Cert 70-532 : Developing Microsoft Azure Solutions

    And I’ve just check on my MCP account that I’ve passed successfully the exam. Sourire I’m now a Microsoft Azure Developer Specialist :

    image

    Posted in Azure, English, Microsoft | Tagged , , | Leave a comment

    Ebook Review : Learning Microsoft Azure

     

    During the holidays, I’ve had the opportunity to make a review of the new Ebook written by Geoff Webber-Cross  and edited by PackPublishing :

    image

    You can order the book using this url : http://bit.ly/11BUWXf

     

    This book covers the following subjects around the Microsoft Azure Platform :

     

    Continue reading

    Posted in Azure, English, Microsoft | Tagged , , | Leave a comment