Giter Club home page Giter Club logo

cdk-kubernetes-haproxy-example's Introduction

HA Proxy on AWS Stack

Overview

This is an example of how to define some simple infrastructure in AWS to support haproxy served on kubernetes.

A CDK stack compromising of a VPC, Elastic Container Repository and Elastic Kubernetes Service are described in /bin and /lib.

Kubernetes deployment and service definitions are in /kubernetes.

A docker image for haproxy is available in /docker.

Deployment pipeline steps

  1. Deploy the AWS infrastructure using the AWS CDK.
  2. Build haproxy docker image.
  3. Push haproxy docker image to our ECR respository.
    • The image path could be hard coded if this will only ever be deployed to one region otherwise we will have to pull in the current account details and build up a repository URL or add a URL output to the ECR stack.
  4. Using kubectl deploy the haproxy deployment and service

Out of scope

  • Monitoring of EKS (use cloudwatch alarms as a starting point)
    • More advanced monitoring solutions are available eg datadog, grafana etc
  • AWS Load balancer
    • A network load balancer would be suitable unless using a fargate deployment then only application load balancers are allowed.
    • EKS supports creating load balancers through annotating the service eg
    • service.beta.kubernetes.io/aws-load-balancer-type: nlb
  • Service discovery
    • Kubernetes provides a mechanism for service discovery by default however our application might not live in the cluster

cdk-kubernetes-haproxy-example's People

Contributors

cookejames avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.