gcp / gke / k8s microservices

Similar documents
Cloud-Native Applications. Copyright 2017 Pivotal Software, Inc. All rights Reserved. Version 1.0

Copyright 2016 Pivotal. All rights reserved. Cloud Native Design. Includes 12 Factor Apps

DESIGNING APPLICATIONS FOR CONTAINERIZATION AND THE CLOUD THE 12 FACTOR APPLICATION MANIFESTO

12 Factors to Cloud Success. Rafael Benevides

Building Microservices with the 12 Factor App Pattern

Heroku. Rimantas Kybartas

Deployment Strategies on Kubernetes. By Etienne Tremel Software engineer at Container February 13th, 2017

Implementing the Twelve-Factor App Methodology for Developing Cloud- Native Applications

The 12-Factor app and IBM Bluemix IBM Corporation

Kubernetes Ingress Virtual Service Configuration

Kuber-what?! Learn about Kubernetes

What s New in K8s 1.3

What s New in K8s 1.3

Kubernetes. Introduction

Note: Currently (December 3, 2017), the new managed Kubernetes service on Azure (AKS) does not yet support Windows agents.

Kubernetes Ingress Virtual Service Configuration

Code: Slides:

ASP.NET Core & Docker

Bitnami s Kubernetes Projects Leverage Application delivery on Next Generation Platforms

Services and Networking

Kubernetes deep dive

Introduction to Kubernetes

PARTLY CLOUDY DESIGN & DEVELOPMENT OF A HYBRID CLOUD SYSTEM

Continuous delivery while migrating to Kubernetes

Kubernetes Integration with Virtuozzo Storage

Kubernetes The Path to Cloud Native

Docker Enterprise Edition 2.0 Platform Public Beta Install and Exercises Guide

Creating a Multi-Container Pod

/ Cloud Computing. Recitation 5 February 14th, 2017

Scheduling in Kubernetes October, 2017

EASILY DEPLOY AND SCALE KUBERNETES WITH RANCHER

Question: 2 Kubernetes changed the name of cluster members to "Nodes." What were they called before that? Choose the correct answer:

10 Kube Commandments

Kubernetes 101. Doug Davis, STSM September, 2017

Kubernetes Basics. Christoph Stoettner Meetup Docker Mannheim #kubernetes101

Containers, Serverless and Functions in a nutshell. Eugene Fedorenko


An Introduction to Kubernetes

Kubernetes Integration Guide

DEVELOPER INTRO

VMware Integrated OpenStack with Kubernetes Getting Started Guide. VMware Integrated OpenStack 4.1

12 (15) Factor App Workshop

OpenShift Cheat Sheet

Cloud I - Introduction

Microservices. GCPUG Tokyo Kubernetes Engine

Life of a Packet. KubeCon Europe Michael Rubin TL/TLM in GKE/Kubernetes github.com/matchstick. logo. Google Cloud Platform

Kubernetes: Twelve KeyFeatures

DevOps + Infrastructure TRACK SUPPORTED BY

SAMPLE CHAPTER. Marko Lukša MANNING

A Comparision of Service Mesh Options

Scaling Jenkins with Docker and Kubernetes Carlos

Kubernetes objects on Microsoft Azure

The missing CI/CD Kubernetes component: Helm package manager

Kubernetes on Openstack

Introduction to Kubernetes Storage Primitives for Stateful Workloads

Implementing SaaS on Kubernetes

Kubernetes introduction. Container orchestration

Overview of Container Management

what's in it for me? Ian Truslove :: Boulder Linux User Group ::

Knative: Building serverless platforms on top of Kubernetes

Secure Kubernetes Container Workloads

TDD of Python Microservices. Michał Bultrowicz

Disclaimer This presentation may contain product features that are currently under development. This overview of new technology represents no commitme

Efficiently exposing apps on Kubernetes at scale. Rasheed Amir, Stakater

Building an on premise Kubernetes cluster DANNY TURNER

Implementing Container Application Platforms with Cisco ACI

RUNNING VIRTUAL MACHINES ON KUBERNETES. Roman Mohr & Fabian Deutsch, Red Hat, KVM Forum, 2017

Delivering Kubernetes Apps with Helm. Michelle Adnan Adam

Disclaimer This presentation may contain product features that are currently under development. This overview of new technology represents no commitme

How to Re-Architect without Breaking Stuff (too much) Owen Garrett March 2018

Disclaimer This presentation may contain product features that are currently under development. This overview of new technology represents no commitme

/ Cloud Computing. Recitation 5 September 26 th, 2017

Microservices. Chaos Kontrolle mit Kubernetes. Robert Kubis - Developer Advocate,

Building a Microservices Platform, Patterns and Best Practices

Deep Dive on Microservices and ECS

Delivering Microservices Securely and at Scale with NGINX in Red Hat OpenShift. November, 2017

StreamSets Control Hub Installation Guide

Ingress Kubernetes Tutorial

Fault Tolerant Stateful Services on Kubernetes. Timothy St.

Running Containerized Microservices on AWS. November 2017

Cloud Native Architecture 300. Copyright 2014 Pivotal. All rights reserved.

Continuous Delivery the hard way with Kubernetes. Luke Marsden, Developer

So, I have all these containers! Now what?

Red Hat OpenShift Roadmap Q4 CY16 and H1 CY17 Releases. Lutz Lange Solution

Leveraging the Serverless Architecture for Securing Linux Containers

Table of Contents. Section 1: Overview 3 NetScaler Summary 3 NetScaler CPX Overview 3

CONTAINERS AND MICROSERVICES WITH CONTRAIL

@briandorsey #kubernetes #GOTOber

WHITE PAPER. RedHat OpenShift Container Platform. Benefits: Abstract. 1.1 Introduction

A REFERENCE ARCHITECTURE FOR DEPLOYING WSO2 MIDDLEWARE ON KUBERNETES

Running MarkLogic in Containers (Both Docker and Kubernetes)

Infoblox IPAM Driver for Kubernetes User's Guide

Infoblox IPAM Driver for Kubernetes. Page 1

Developing Kubernetes Services

Service Mesh with Istio on Kubernetes. Dmitry Burlea Software FlixCharter

Building a Microservices Platform with Kubernetes. Matthew Mark

A day in the life of a log message Kyle Liberti, Josef

OpenShift 3 Technical Architecture. Clayton Coleman, Dan McPherson Lead Engineers

NGINX: From North/South to East/West

Declarative Modeling for Cloud Deployments

Transcription:

gcp / gke / k8s microservices managing microservices with kubernetes 08.17.2016 Austin GCPUG Lou Scalpati CTO RxWiki

microservices What are Microservices generally REST APIs returning json organized around function: a user service, crud for db app or a url shortening service small units of an app but are standalone Why Microservices? modular easy to deploy scales independently Reduces maintenance issues uncouples components of your app - changes can be deployed without having to test entire codebase reusable usually a single developer or small team can create / manage mixed language environment

monolithic vs microservices https://www.safaribooksonline.com/library/view/kubernetes-cookbook/9781785880063/ch05s02.html

the 12 Factor App (or 12 factor microservice) I. Codebase (git) One codebase tracked in revision control, many deploys II. Dependencies (vendoring) Explicitly declare and isolate dependencies III. Config (docker) Store config in the environment IV. Backing services (docker/k8s) Treat backing services as attached resources V. Build, release, run (docker/k8s) Strictly separate build and run stages VI. Processes (docker/k8s) Execute the app as one or more stateless processes VII. Port binding (docker/k8s) Export services via port binding VIII. Concurrency (docker/k8s) Scale out via the process model IX. Disposability (docker) Maximize robustness with fast startup and graceful shutdown X. Dev/prod parity (docker/k8s) Keep development, staging, and production as similar as possible XI. Logs (docker/k8s) Treat logs as event streams XII. Admin processes (k8s) Run admin/management tasks as one-off processes

what is Kubernetes (k8s) What it does application configuration service Discovery managing Updates monitoring containers PAAS that manages your application deployment and operations Commonly used components pods deployments replicasets /replication controllers services labels (tag) driven

k8s Pods and Services Pods tightly coupled containers scaled together shared: Namespace Volumes IP short life span - spin up and down quickly Services defines a logical set of pods defines access policy to pods really a microservice Targets pods by label selector base unit for service discovery More permanent than pods

the architecture (the obligatory diagram) internet Service Load Balancer Service Service Pod Pod Pod Pod Pod Pod

deployments and ReplicaSets Deployments combines pods and scaling policies declarative updates for Pods and Replica Sets describe the desired state deployment controller will: change the actual state to the desired state Control rate of change Rollback to an earlier Deployment revision History ReplicaSets the next-generation Replication Controller works as part of a deployment can be used standalone (but why?)

creating a deployment apiversion: extensions/v1beta1 kind: Deployment metadata: name: nginx-deployment spec: replicas: 3 template: metadata: labels: app: nginx spec: containers: - name: nginx image: nginx:1.7.9 ports: - containerport: 80 create a deployment $ kubectl create -f docs/user-guide/nginx-deployment.yaml --record deployment "nginx-deployment" created get deployment status $ kubectl get deployments NAME DESIRED CURRENT UP-TO-DATE AVAILABLE AGE nginx-deployment 3 3 3 3 18s get ReplicaSet Status $ kubectl get rs NAME DESIRED CURRENT AGE nginx-deployment-2035384211 3 3 18s

fun with deployments (updates and rollouts) updating a deployment (rollout) $ kubectl set image deployment/nginx-deployment nginx=nginx:1.9.1 deployment "nginx-deployment" image updated or edit the yaml (rollout) and $ kubectl edit deployment/nginx-deployment deployment "nginx-deployment" edited status of deployment (rollout) $ kubectl rollout status deployment/nginx-deployment deployment nginx-deployment successfully rolled out shows the status (new and old) $ kubectl get rs NAME DESIRED CURRENT AGE nginx-deployment-1564180365 3 3 6s nginx-deployment-2035384211 0 0 36s

deployment history check history $ kubectl rollout history deployment/nginx-deployment deployments "nginx-deployment": REVISION CHANGE-CAUSE 1 kubectl create -f docs/user-guide/nginx-deployment.yaml --record 2 kubectl set image deployment/nginx-deployment nginx=nginx:1.9.1 3 kubectl set image deployment/nginx-deployment nginx=nginx:1.91

deployment history (details of a point in time) $ kubectl rollout history deployment/nginx-deployment --revision=2 deployments "nginx-deployment" revision 2 Labels: app=nginx pod-template-hash=1159050644 Annotations: kubernetes.io/change-cause=kubectl set image deployment/nginx-deployment nginx=nginx:1.9.1 Containers: nginx: Image: nginx:1.9.1 Port: 80/TCP QoS Tier: cpu: BestEffort memory: BestEffort Environment Variables: <none> No volumes.

roll back (this is why to use deployments) undo! $ kubectl rollout undo deployment/nginx-deployment deployment "nginx-deployment" rolled back roll back to a point in time! $ kubectl rollout undo deployment/nginx-deployment --to-revision=2 deployment "nginx-deployment" rolled back Note: Kubectl rolling update updates Pods and Replication Controllers in a similar fashion. But Deployments are recommended, since they are declarative, server side, and have additional features, such as rolling back to any previous revision even after the rolling update is done.

load balancing options GCP network load balancer automatic defined in service connects directly to service layer 3 no SSL GLBC k8s L7 Load balancer Still beta Layer 7 configure ingress objects does not clean up all network resources no SSL (?? ingress object) GCP HTTP/HTTPS Load Balancer manual config SSL Certificate process?? nginx defacto standard reverse proxy supports SSL layer 7 needs configuration easy to deploy haproxy versatile L3,4,5,6,7 designed for network proxy what I use many others

resources the 12 factors: http://goo.gl/ay6ov K8s services: http://goo.gl/gcuj8j k8s deployments: http://goo.gl/dtgty1 k8s microservices course (free): https://goo.gl/tfkns3