Slide 1

Slide 1 text

Nicolás Paez | @inicopaez | [email protected] Consideraciones de diseño para un modelo de infraestructura Octubre 2018 | ArqConf

Slide 2

Slide 2 text

Modelos de Infraestructura Resumen: De la mano de DevOps, SREs y un conjunto de herramientas, la práctica de Infraestructura como Código ha adquirido una gran popularidad en los últimos años. La adopción de esta práctica implica una toma de decisiones que entre otras cosas incluye el diseño de un modelo de infraestructura y la selección de herramientas asociadas. En esta sesión veremos un conjunto de conceptos y recomendaciones para tomar estas decisiones de cara a una efectiva implementación de la práctica de Infraestructura como Código.

Slide 3

Slide 3 text

Agenda Context Challenge 1 Challenge 2 Challenge 3 Demo!

Slide 4

Slide 4 text

http://cor.to/arqconf1110

Slide 5

Slide 5 text

No content

Slide 6

Slide 6 text

Context

Slide 7

Slide 7 text

Once upon a time...

Slide 8

Slide 8 text

Humans Beasts

Slide 9

Slide 9 text

Vampires Werewolves

Slide 10

Slide 10 text

Blade

Slide 11

Slide 11 text

Vampires + Humans

Slide 12

Slide 12 text

No content

Slide 13

Slide 13 text

No content

Slide 14

Slide 14 text

Business IT

Slide 15

Slide 15 text

Development developers software Operations sysadmins hardware

Slide 16

Slide 16 text

Agile

Slide 17

Slide 17 text

Development + Business

Slide 18

Slide 18 text

Continuous integration Information radiators Acceptance environments Frequent releases

Slide 19

Slide 19 text

D e v p s

Slide 20

Slide 20 text

> Operations as first-class citizen > Make dev responsible for prod incidents > Formal deployment process > Continuous Delivery > Infrastructure as code DevOps Principles https://www.amazon.com/DevOps-Software-Architects-Perspective-Engineering/dp/0134049845

Slide 21

Slide 21 text

No content

Slide 22

Slide 22 text

No content

Slide 23

Slide 23 text

Business as usual

Slide 24

Slide 24 text

Environments Local Dev Test Prod Dev

Slide 25

Slide 25 text

Challenge #1: Infrastructure model

Slide 26

Slide 26 text

On Premises IaaS PaaS SaaS Application Application Application Application Data Data Data Data Runtime Runtime Runtime Runtime Middleware Middleware Middleware Middleware OS OS OS OS Virtualization Virtualization Virtualization Virtualization Networking Networking Networking Networking Servers Servers Servers Servers

Slide 27

Slide 27 text

On Premises IaaS PaaS SaaS Application Application Application Application Data Data Data Data Runtime Runtime Runtime Runtime Middleware Middleware Middleware Middleware OS OS OS OS Virtualization Virtualization Virtualization Virtualization Networking Networking Networking Networking Servers Servers Servers Servers AWS/EC2 GCE Azure Heroku AppHarbor Beanstalk GApps Office365

Slide 28

Slide 28 text

Virtual Machines vs. Containers

Slide 29

Slide 29 text

Challenge #2: Mutable vs. Inmutable

Slide 30

Slide 30 text

Mutable Infrastructure Test You package your app and make it run on different infrastructure Prod app-v1 app-v1 app-v1 OS OS OS Runtime Runtime Runtime

Slide 31

Slide 31 text

Mutable Infrastructure Test You package your app and make it run on different infrastructure Prod app-v1 app-v1 app-v1 OS OS OS Runtime Runtime Runtime app-v2 app-v2 app-v2

Slide 32

Slide 32 text

Immutable Infrastructure Test You package your app with its infrastructure Prod App-v1 + Runtime App-v1 + Runtime App-v1 + Runtime OS OS Engine OS Engine Engine

Slide 33

Slide 33 text

Immutable Infrastructure Test You package your app with its infrastructure Prod App-v1 + Runtime App-v1 + Runtime App-v1 + Runtime OS OS Engine OS Engine Engine App-v2 + Win2016 App-v2 + Win2016 App-v2 + Win2016

Slide 34

Slide 34 text

Challenge #3: Tools Selection

Slide 35

Slide 35 text

Automation Layers Layer 2: base software (db engine, web server, app server) Layer 1: OS & Networking Layer 3: Apps (binaries, configuration, data)

Slide 36

Slide 36 text

Automation Layers Layer 2: base software (db engine, web server, app server) Layer 1: OS & Networking Layer 3: Apps (binaries, configuration, data) Ansible, Chef, Puppet, SaltStack Terraform, Vagrant, CloudFormation Jenkins, TeamCity, Spinnaker

Slide 37

Slide 37 text

Automation Layers Layer 2: base software (db engine, web server, app server) Layer 1: OS & Networking Layer 3: Apps (binaries, configuration, data) Ansible, Chef, Puppet, SaltStack Terraform, Vagrant, CloudFormation Jenkins, TeamCity, Spinnaker

Slide 38

Slide 38 text

Demo time!

Slide 39

Slide 39 text

Demo 1: mutable infrastructure Terraform Ansible Jenkins Ubuntu Server Nginx, Ruby, PostgreSQL WebApp, DB http://blog.nicopaez.com/2015/09/05/capas-de-automatizacion/ Git Repos ● App ● Config ● Infra ● Scripts DigitalOcean (IaaS)

Slide 40

Slide 40 text

Demo 1: mutable infrastructure PostgreSQL Upstart process Ruby/Padrino WebApp Nginx (reverse proxy) Ubuntu 14.04 Digital Ocean Cloud

Slide 41

Slide 41 text

Demo 2: inmutable infrastructure Ruby, Puma, PostgreSQL WebApi Git Repos ● App ● Config ● Scripts OpenShift (PaaS) Jenkins Docker

Slide 42

Slide 42 text

Demo 2: inmutable infrastructure PostgreSQL Puma Web Server Ruby / Padrino App OpenShift Service OpenShift Platform

Slide 43

Slide 43 text

Fin