Despliegue de Aplicaciones .Net Core en Docker

Post on 16-Apr-2017

79 views 2 download

Transcript of Despliegue de Aplicaciones .Net Core en Docker

Despliegue de aplicaciones .net Core en DockerErnesto Cárdenas Cangahuala

@fisica3www.consultorinternet.com 200

Presentación

• Ing. Informático• Microsoft Influencer

Developer• Fotógrafo aficionado• Algún tiempo “fuera” ;)• @agileperu• www.consultorinternet.c

om

Un poco de contexto..

Historia de las aplicaciones distribuidas

Static website

Web frontend

User DB

Queue Analytics DB

Background workers API

endpoint

nginx 1.5 + modsecurity + openssl + bootstrap 2

postgresql + pgv8 + v8

hadoop + hive + thrift + OpenJDK

Ruby + Rails + sass + Unicorn

Redis + redis-sentinel

Python 3.0 + celery + pyredis + libcurl + ffmpeg + libopencv + nodejs + phantomjs

Python 2.7 + Flask + pyredis + celery + psycopg + postgresql-client

Development VM

QA server

Public Cloud

Disaster recovery

Contributor’s laptopProduction

Servers

Aplicaciones distribuidas…M

ultip

licity

of

Stac

ks

Mul

tiplic

ity o

f ha

rdw

are

envi

ronm

ents

Production Cluster

Customer Data Center

Do services and apps interact

appropriately?

Can I migrate

smoothly and quickly?

Gestión y despliegue de aplicaciones distribuidas

Static website

Web frontend

Background workers

User DB

Analytics DB

Queue

Dev VM QA ServerSingle Prod

ServerOnsite Cluster Azure Contributo

r laptopCustomer Servers

? ? ? ? ? ? ?

? ? ? ? ? ? ?

? ? ? ? ? ? ?

? ? ? ? ? ? ?

? ? ? ? ? ? ?

? ? ? ? ? ? ?

La inspiración para los contenedores

Mul

tiplic

ity o

f Go

ods

Mul

tipili

city

of

met

hods

for

tran

spor

ting

&

stor

ing

Do I worry about

how goods interact

(e.g. coffee beans next to spices)

Can I transport quickly and sm

oothly(e.g. from

boat to train to truck)

La Inspiración: Transporte de mercancias Pre-1960

Mul

tiplic

ity o

f Go

ods

Mul

tiplic

ity o

f m

etho

ds fo

r tr

ansp

ortin

g/st

orin

g

Do I worry about

how goods interact

(e.g. coffee beans next to spices)

Can I transport quickly and sm

oothly(e.g. from

boat to train to truck)

Solución: Ecosistema Intermodal de Contenedores de carga

…in between, can be loaded and unloaded, stacked, transported efficiently over long distances, and transferred from one mode of transport to another

A standard container that is loaded with virtually any goods, and stays sealed until it reaches final delivery.

Ecosistema Intermodal de Contenedores de carga

90% de toda la carga es ahora despachada en un contenedor estandar

Grandes reducciones de coste y de tiempo de carga/descarga de los barcos

Disminución de perdidas debido a robo o daño

Enorme reducción en costos de flete como parte del precio final de los bienes (de >25% a <3%)

Globalización masiva

5000 barcos despachan 200M de contenedores por año

Pre-

1960

Toda

y

Desplegando usando contenedores

Static website

Web frontend

Background workers

User DB

Analytics DB

Queue

Dev VM QA ServerSingle Prod

ServerOnsite Cluster Azure Contributo

r laptopCustomer Servers

Los contenedores eliminan la matriz

Ecosistema DockerHost MachineDocker Client

Docker Hub

Docker Deamon

Container A

Container B

Source Code Repo

Create

Delete

List

Push

Pull

AppA

Hypervisor (Type 2)

Host OS

Server

GuestOS

Bins/Libs

AppA’

GuestOS

Bins/Libs

AppB

GuestOS

Bins/Libs

App A’

Host OS

Server

Bins/Libs

App ABins/Libs

App B

App B’

App B’

App B’VM

Container

Los Contenedores están aislados, pero comparten el kernel y eventualmente librerías del SO

GuestOS

GuestOS

…lo que resulta en un despliegue mas rápido, menos carga, migración sencilla y reinicio mas rápido

MVs vs Contenedores

Docker Deamon

Y por otro lado, aquí…

2014…¡Qué bien pinta eso de Docker!

Official Repos & 14K+ Dockerized Apps

Community640+ Contributors250+ Meetups on Docker38M Downloads16K Projects on GitHub

SupportEnterprise SupportRobust DocumentationImplementation, Integration, Training Network of Partners

The Docker Platform

Docker Engine Docker Hub Build, Ship, and Run

Partners

Content

Users

Official Repos &35 K Dockerized Apps

2015 A ver probemos…

¡Manos a la obra!

Lecciones aprendidas• Hyper-V facilita el trabajo con

Docker a los desarrolladores Windows (¡No excusas!)

• Visual Studio Team Services provee una orquestación clara para el despliegue de contenedores Docker

• .Net Core ya esta listo para usar, pero hay que fijarse en los detalles

• Docker sigue evolucionando, asegurémonos que todas nuestras versiones estén alineadas

• A ver que nos trae Nano Server

¿Preguntas?

@fisica3

Click icon to add picture

www.consultorinternet.comwww.colinsalmcorner.comwww.donovanbrown.com