SlideShare a Scribd company logo
© 2016 Mesosphere, Inc. All Rights Reserved.
VELOCITY NYC | SEPTEMBER 20, 2016
CONTINUOUS
DELIVERY WITH
DC/OS AND
JENKINS
© 2016 Mesosphere, Inc. All Rights Reserved.
SUNIL SHAH
Product Manager at Mesosphere
@ssk2
ROGER IGNAZIO
Tech Lead at Mesosphere
@rogerignazio
WHO WE ARE
© 2016 Mesosphere, Inc. All Rights Reserved.
mesosinaction.com
Use the code vecymes for
42% off!
BUY MY BOOK!
© 2016 Mesosphere, Inc. All Rights Reserved.
AGENDA
Lecture
● Introduction to Apache Mesos and DC/OS
● Components that make up modern infra.
● Running Jenkins as a service on DC/OS
● Continuously deploying applications to DC/OS
Demos & Lab
● Installing and configuring Jenkins
● Installing and configuring a load balancer
● Creating a new CI/CD pipeline
● Putting it all together (CD in practice)
© 2016 Mesosphere, Inc. All Rights Reserved.
DEVELOPER AGILITY,
DEFINED
© 2016 Mesosphere, Inc. All Rights Reserved.
Developer agility empowers developers to
● ship their apps to production
● leverage the power of Mesos and DC/OS
● fix bugs rapidly
without downtime!
DEVELOPER AGILITY, DEFINED
© 2016 Mesosphere, Inc. All Rights Reserved.
Continuous integration is not the same as
continuous delivery or continuous deployment.
DEVELOPER AGILITY, DEFINED
© 2016 Mesosphere, Inc. All Rights Reserved.
An artifact repo stores built binaries, whereas an
image registry stores templates for deployment.
DEVELOPER AGILITY, DEFINED
© 2016 Mesosphere, Inc. All Rights Reserved.
DEVELOPER AGILITY, DEFINED
© 2016 Mesosphere, Inc. All Rights Reserved.
INTRO TO
APACHE MESOS
AND DC/OS
© 2016 Mesosphere, Inc. All Rights Reserved.
A QUICK PRIMER ON CONTAINERS
Physical Server
Virtual Machine–Based
Application Deployment
Container–Based
Application Deployment
Hypervisor
OS
VM VM
OS
App App
Physical Server
Hypervisor
OS
VM VM
OS
App App
Physical Server
Operating System
App App
Physical Server
Operating System
App App
Mesos
Isolate apps by running
multiple VMs per physical
server; still need to
manage each guest OS!
Isolate apps using
features of the host OS,
such as Linux cgroups.
© 2016 Mesosphere, Inc. All Rights Reserved.
A QUICK PRIMER ON CONTAINERS
Linux cgroup
Dependencies
Linux Host OS
Application
Docker Container
Dependencies
Host OS
Application
Linux cgroupsDocker Containers
VM
Dependencies
Hypervisor
Application
Virtual Machines
Guest OS
Docker Engine
© 2016 Mesosphere, Inc. All Rights Reserved.
A BIT OF CLARIFICATION
https://mesos.apache.org https://dcos.io
© 2016 Mesosphere, Inc. All Rights Reserved.
● General purpose cluster resource manager
● Represents many machines as a single entity
● Advertises resources directly to frameworks
● Works at scale: Apple, Twitter, Airbnb, Netflix, …
WHAT IS MESOS?
© 2016 Mesosphere, Inc. All Rights Reserved.
● Two-tier scheduling across resource types
● cpus, mem, disk, and ports by default
● Masters are highly available, agents are fault tolerant
● Checkpointing, agent recovery
● Resource isolation between processes
● Linux cgroups, Docker, …
● Language bindings: C++, Java, Python, Go, …
WHAT IS MESOS? (CONTINUED)
© 2016 Mesosphere, Inc. All Rights Reserved.
MESOS ARCHITECTURE
Launch task(s)
Mesos Master Quorum
Mesos Master
(Standby)
ZK
Mesos Master
(Standby)
ZK
Mesos Master
(Leader)
ZK
Framework B
Scheduler
Agent 1
Framework A
Executor
Task(s)
Agent n
Framework A
Executor
Task(s)
Framework B
Executor
Task(s)
Resource offer
Resource offer
Framework A
Scheduler
Launch task(s)
© 2016 Mesosphere, Inc. All Rights Reserved.
ANATOMY OF A RESOURCE OFFER (TWO-TIER SCHEDULING)
Mesos Master(s)
Mesos Agent
16 CPUs
128 GB RAM
1 TB disk
Mesos Agent
16 CPUs
128 GB RAM
1 TB disk
Mesos Agent
16 CPUs
128 GB RAM
1 TB disk
Master offers resources
to scheduler
Scheduler
Executor
Available compute resources
Resource offer accepted, launch executors/tasks
Tasks
Executor
Tasks
Executor
Tasks
Scheduler accepts or
declines an offer
© 2016 Mesosphere, Inc. All Rights Reserved.
● Service discovery and load balancing
● BIND, Mesos-DNS, Consul-Mesos, Marathon-LB
NEW (OLD) PROBLEMS
© 2016 Mesosphere, Inc. All Rights Reserved.
● Service discovery and load balancing
● BIND, Mesos-DNS, Consul-Mesos, Marathon-LB
● Monitoring and metrics collection
● Collectd, Nagios, Prometheus, Snap
NEW (OLD) PROBLEMS
© 2016 Mesosphere, Inc. All Rights Reserved.
● Service discovery and load balancing
● BIND, Mesos-DNS, Consul-Mesos, Marathon-LB
● Monitoring and metrics collection
● Collectd, Nagios, Prometheus, Snap
● Persistent storage (filesystems, databases,
etc)
● Ceph, HDFS, Amazon EBS / EFS / S3, NFS, Cassandra
NEW (OLD) PROBLEMS
© 2016 Mesosphere, Inc. All Rights Reserved.
● Service discovery and load balancing
● BIND, Mesos-DNS, Consul-Mesos, Marathon-LB
● Monitoring and metrics collection
● Collectd, Nagios, Prometheus, Snap
● Persistent storage (filesystems, databases,
etc)
● Ceph, HDFS, Amazon EBS / EFS / S3, NFS, Cassandra
● Administration: named URIs vs. ports, IPAM
● Nginx, HAProxy, Mesos-DNS, dhcpd, Minuteman
NEW (OLD) PROBLEMS
© 2016 Mesosphere, Inc. All Rights Reserved.
https://dcos.io
https://github.com/dcos
DC/OS:
BUILT ON
MESOS
© 2016 Mesosphere, Inc. All Rights Reserved.
DC/OS:
BUILT ON
MESOS
© 2016 Mesosphere, Inc. All Rights Reserved.
All of the benefits of Mesos, plus
● Built-in service discovery and load balancing
● Support for stateful services
● Turn-key installation of distributed systems
● Cloud-agnostic installer
● Web and command-line interfaces
● All components are integration tested and supported by
Mesosphere, Inc.
MESOS AND DC/OS: BETTER TOGETHER
© 2016 Mesosphere, Inc. All Rights Reserved.
JENKINS ON
DC/OS
© 2016 Mesosphere, Inc. All Rights Reserved.
MULTIPLE JENKINS MASTERS
Team A Jenkins
. . .
Jenkins Agent 1
Jenkins Agent 2
. . .
Jenkins Agent N
Team B Jenkins
Jenkins Agent 1
Jenkins Agent 2
. . .
Jenkins Agent N
Team X Jenkins
Jenkins Agent 1
Jenkins Agent 2
. . .
Jenkins Agent N
© 2016 Mesosphere, Inc. All Rights Reserved.
MULTIPLE JENKINS MASTERS → STATIC PARTITIONING
Team A Jenkins
. . .
Jenkins Agent 1
Jenkins Agent 2
. . .
Jenkins Agent N
Team B Jenkins
Jenkins Agent 1
Jenkins Agent 2
. . .
Jenkins Agent N
Team X Jenkins
Jenkins Agent 1
Jenkins Agent 2
. . .
Jenkins Agent N
90% Utilized
(Normal)
140% Utilized
(40 builds in queue)
0% Utilized
(Idle)
© 2016 Mesosphere, Inc. All Rights Reserved.
RUNNING JENKINS ON DC/OS → FAIR SHARING
Team A Jenkins . . .
DC/OS Agent 1
DC/OS Agent 4
DC/OS Agent N
Team B Jenkins
DC/OS Agent 2
DC/OS Agent 5
Team X Jenkins
DC/OS Agent 3
DC/OS Agent 6
. . .
DC/OS
© 2016 Mesosphere, Inc. All Rights Reserved.
CONTINUOUSLY
DEPLOYING
APPLICATIONS TO
DC/OS
© 2016 Mesosphere, Inc. All Rights Reserved.
TRADITIONAL RELEASE PROCESS
● Planning & implementing new
technologies
● Waiting for people &
infrastructure
● Building environment specific
CI/CD for each project
● Moving apps from dev to staging
to prod
DEV(OPS) TEAMS SPEND SIGNIFICANT TIME AND EFFORT ON:
PROJECT
PLANNING
WEEK 1 WEEK 2 WEEK 3 WEEKS 4 TO 8 WEEK 9
CUSTOMER
FEEDBACKCONFIGURATIONRESOURCE
ALLOCATION
Dev
Test Stage
Release
© 2016 Mesosphere, Inc. All Rights Reserved.
MODERN RELEASE PROCESS
WEEK 1 WEEK 2 WEEK 3 WEEK 4
PROJECT
PLANNING
CUSTOMER
FEEDBACK
CUSTOMER
FEEDBACK
CUSTOMER
FEEDBACK
RELEASE 1 RELEASE 2 RELEASE 3 RELEASE 4
Better products through a
repeatable release cadence
Happier customers through
continuous feedback
Dev
Test Stage
Release Dev
Test Stage
Release
Dev
Test Stage
Release Dev
Test Stage
Release
© 2016 Mesosphere, Inc. All Rights Reserved.
● Scheduling — advertising available compute resources
● Deployments — getting an application onto a node
● Health checks — ensuring the app/service is healthy
● Service discovery — connecting to dependent services
● Persistence — running stateful services in containers
DEPLOYING APPLICATIONS: BASIC REQUIREMENTS
© 2016 Mesosphere, Inc. All Rights Reserved.
A sysadmin provisions one or more
physical/virtual servers to host the app
Mesos resource offers (two-tier
scheduling) offers available resources
directly to frameworks
DEPLOYING APPLICATIONS: SCHEDULING
Before DC/OS With DC/OS
© 2016 Mesosphere, Inc. All Rights Reserved.
By hand or using Puppet / Chef /
Ansible
Jenkins SSHing to the machine and
running a shell script
Note: all dependencies must also be present!
Marathon deploys containers, ideally
using a CI/CD tool to create/update
app definitions
Docker containers packages app and
dependencies
DEPLOYING APPLICATIONS: DEPLOYMENTS
Before DC/OS With DC/OS
© 2016 Mesosphere, Inc. All Rights Reserved.
Nagios pages a sysadmin
Marathon performs health checks,
restarts unhealthy/failed instances
DEPLOYING APPLICATIONS: HEALTH CHECKS
Before DC/OS With DC/OS
© 2016 Mesosphere, Inc. All Rights Reserved.
Static hostnames / IP addresses in a
spreadsheet or config management
A sysadmin configures a load balancer
manually or with Puppet / Chef /
Ansible
Mesos-DNS provides DNS resolution for
running services (hostname / IP
address, ports, etc)
Load balancer configs built
dynamically using cluster state
DEPLOYING APPLICATIONS: SERVICE DISCOVERY
Before DC/OS With DC/OS
© 2016 Mesosphere, Inc. All Rights Reserved.
Individual servers with RAID 1/5/6/10,
expensive SANs, NFS, etc.
Dedicated, statically partitioned Ceph
or Gluster storage clusters
Mesos external/persistent volumes
(REX-Ray), HDFS, etc.
Self-healing Ceph or Gluster on Mesos /
DC/OS
DEPLOYING APPLICATIONS: PERSISTENCE
Before DC/OS With DC/OS
© 2016 Mesosphere, Inc. All Rights Reserved.
Q: Given that we are all engineers,
which tools would we like to work with?
© 2016 Mesosphere, Inc. All Rights Reserved.
DEMOS & LAB
© 2016 Mesosphere, Inc. All Rights Reserved. 40
PIPELINE COMPONENTS
Continuous
Integration
Container
Registry
Container
Orchestrator
Version Control
System
Load Balancer
Production
Environment
Continuous Delivery Pipeline
git push
DC/OS
© 2016 Mesosphere, Inc. All Rights Reserved. 41
PIPELINE COMPONENTS
Jenkins
DockerHub
MarathonGitHub Marathon-lbMesos
Continuous Delivery Pipeline
git push
DC/OS
© 2016 Mesosphere, Inc. All Rights Reserved. 42
PIPELINE CONFIGURATION
Jenkinsfile
Dockerfile
marathon.json
Continuous Delivery Pipeline
git push
DC/OS
© 2016 Mesosphere, Inc. All Rights Reserved.
A SNEAK PREVIEW
© 2016 Mesosphere, Inc. All Rights Reserved.
● Head over to github.com/mesosphere/vny
● Follow the exercises!
● Use the username/password: velocityuser/velocitypassword
YOUR TURN
© 2016 Mesosphere, Inc. All Rights Reserved.
Roger Ignazio
roger@mesosphere.com
@rogerignazio
Sunil Shah
sunil@mesosphere.com
@ssk2
THANK YOU!
Learn more by visiting DCOS.io and Mesosphere.com

More Related Content

What's hot (20)

PDF
Deploying containers and managing them on multiple Docker hosts, Docker Meetu...
dotCloud
 
PDF
Java EE and NoSQL using JBoss EAP 7 and OpenShift
Arun Gupta
 
PDF
Mesos and containers
Jiang Yan Xu
 
PDF
DCEU 18: Automating Docker Enterprise: Hands-off Install and Upgrade
Docker, Inc.
 
PDF
[NYC Meetup] Docker at Nuxeo
Nuxeo
 
PPTX
Docker Container As A Service - JAX 2016
Patrick Chanezon
 
PDF
Apache Mesos: a simple explanation of basics
Gladson Manuel
 
PDF
Scaling and Embracing Failure: Clustering Docker with Mesos
Rob Gulewich
 
PPTX
Dealing with kubesprawl tetris style !
Taco Scargo
 
PDF
AtlasCamp 2015: The age of orchestration: From Docker basics to cluster manag...
Atlassian
 
PDF
Mesos: The Operating System for your Datacenter
David Greenberg
 
PPTX
Intro Docker october 2013
dotCloud
 
PDF
Continuous delivery with Jenkins, Docker and Mesos/Marathon - jbcnconf
Julia Mateo
 
PDF
Docker for Java Developers
NGINX, Inc.
 
PDF
Docker zero
Manuel de la Peña Peña
 
PDF
DCEU 18: Tips and Tricks of the Docker Captains
Docker, Inc.
 
PDF
KubeCon 2017: Kubernetes from Dev to Prod
Subhas Dandapani
 
PDF
A DevOps guide to Kubernetes
Paul Czarkowski
 
PPTX
7+1 myths of the new os
Alexis Richardson
 
PDF
Docking your services_with_docker
Tikal Knowledge
 
Deploying containers and managing them on multiple Docker hosts, Docker Meetu...
dotCloud
 
Java EE and NoSQL using JBoss EAP 7 and OpenShift
Arun Gupta
 
Mesos and containers
Jiang Yan Xu
 
DCEU 18: Automating Docker Enterprise: Hands-off Install and Upgrade
Docker, Inc.
 
[NYC Meetup] Docker at Nuxeo
Nuxeo
 
Docker Container As A Service - JAX 2016
Patrick Chanezon
 
Apache Mesos: a simple explanation of basics
Gladson Manuel
 
Scaling and Embracing Failure: Clustering Docker with Mesos
Rob Gulewich
 
Dealing with kubesprawl tetris style !
Taco Scargo
 
AtlasCamp 2015: The age of orchestration: From Docker basics to cluster manag...
Atlassian
 
Mesos: The Operating System for your Datacenter
David Greenberg
 
Intro Docker october 2013
dotCloud
 
Continuous delivery with Jenkins, Docker and Mesos/Marathon - jbcnconf
Julia Mateo
 
Docker for Java Developers
NGINX, Inc.
 
DCEU 18: Tips and Tricks of the Docker Captains
Docker, Inc.
 
KubeCon 2017: Kubernetes from Dev to Prod
Subhas Dandapani
 
A DevOps guide to Kubernetes
Paul Czarkowski
 
7+1 myths of the new os
Alexis Richardson
 
Docking your services_with_docker
Tikal Knowledge
 

Viewers also liked (16)

PDF
Paris Container Day 2016 : Deep dive dc-os ci-cd (Mesosphere & Container Solu...
Publicis Sapient Engineering
 
PPTX
Microservices and Container Management with NGINX Plus and Mesosphere DC/OS
NGINX, Inc.
 
PPTX
It All Started With a Wager About System Upgrades
Threat Stack
 
PDF
Building a deployment pipeline
Noam Shochat
 
PDF
Building Self-Defending Applications With OWASP AppSensor JavaOne 2016
jtmelton
 
PDF
Automating the CI / CD pipeline of your containerized applications
Kontena, Inc.
 
PDF
Healthcare application-security-practices-survey-veracode
Veracode
 
ODP
Another 7 tools for your #devops stack
Kris Buytaert
 
PDF
PuppetConf 2016: Continuous Delivery and DevOps with Jenkins and Puppet Enter...
Puppet
 
PDF
AppSensor Near Real-Time Event Detection and Response - DevNexus 2016
jtmelton
 
PDF
CI/CD with Docker, DC/OS, and Jenkins
Karl Isenberg
 
PDF
Build and deploy to the cloud using NetflixOSS (Gradle Summit 2016)
Mike McGarr
 
PPTX
Delivery Pipeline as Code: using Jenkins 2.0 Pipeline
Slawa Giterman
 
PDF
Continuous Delivery at Netflix, and beyond
Mike McGarr
 
PPTX
DevOOPS: Attacks and Defenses for DevOps Toolchains
Chris Gates
 
PDF
Implementing Rolling Upgrades using Mesos, Marathon, Docker, HAProxy
Vivek Juneja
 
Paris Container Day 2016 : Deep dive dc-os ci-cd (Mesosphere & Container Solu...
Publicis Sapient Engineering
 
Microservices and Container Management with NGINX Plus and Mesosphere DC/OS
NGINX, Inc.
 
It All Started With a Wager About System Upgrades
Threat Stack
 
Building a deployment pipeline
Noam Shochat
 
Building Self-Defending Applications With OWASP AppSensor JavaOne 2016
jtmelton
 
Automating the CI / CD pipeline of your containerized applications
Kontena, Inc.
 
Healthcare application-security-practices-survey-veracode
Veracode
 
Another 7 tools for your #devops stack
Kris Buytaert
 
PuppetConf 2016: Continuous Delivery and DevOps with Jenkins and Puppet Enter...
Puppet
 
AppSensor Near Real-Time Event Detection and Response - DevNexus 2016
jtmelton
 
CI/CD with Docker, DC/OS, and Jenkins
Karl Isenberg
 
Build and deploy to the cloud using NetflixOSS (Gradle Summit 2016)
Mike McGarr
 
Delivery Pipeline as Code: using Jenkins 2.0 Pipeline
Slawa Giterman
 
Continuous Delivery at Netflix, and beyond
Mike McGarr
 
DevOOPS: Attacks and Defenses for DevOps Toolchains
Chris Gates
 
Implementing Rolling Upgrades using Mesos, Marathon, Docker, HAProxy
Vivek Juneja
 
Ad

Similar to Highly efficient container orchestration and continuous delivery with DC/OS and Jenkins presentation (20)

PDF
OSDC 2018 | From batch to pipelines – why Apache Mesos and DC/OS are a soluti...
NETWAYS
 
PDF
Elastic data services on Apache Mesos via Mesosphere’s DCOS
harrythewiz
 
PDF
Using DC/OS for Continuous Delivery - DevPulseCon 2017
pleia2
 
PPTX
Webinar: End-to-End CI/CD with GitLab and DC/OS
Mesosphere Inc.
 
PDF
Kubernetes One-Click Deployment: Hands-on Workshop (Munich)
QAware GmbH
 
PDF
Containerizing couchbase with microservice architecture on mesosphere.pptx
Ravi Yadav
 
PDF
Downtime is not an option - day 2 operations - Jörg Schad
Codemotion
 
PDF
Modern Container Orchestration (Without Breaking the Bank)
All Things Open
 
PDF
Hyperscale Computing, Enterprise Agility with Mesosphere
Markus Eisele
 
PPTX
DevOps in Age of Kubernetes
Mesosphere Inc.
 
PDF
DevOps vs. Site Reliability Engineering (SRE) in Age of Kubernetes
DevOps.com
 
PPTX
Episode 4: Operating Kubernetes at Scale with DC/OS
Mesosphere Inc.
 
PDF
DOD 2016 - Jörg Schad - How Fast Data and Microservices Change the Datacenter.
PROIDEA
 
PDF
DCOS Presentation
Jan Repnak
 
PPTX
Episode 3: Kubernetes and Big Data Services
Mesosphere Inc.
 
PDF
Mesos, DC/OS and the Architecture of the New Datacenter
QAware GmbH
 
PDF
[DO16] Mesosphere : Microservices meet Fast Data on Azure
de:code 2017
 
PPTX
Doing Dropbox the Native Cloud Native Way
Minio
 
PPTX
Episode 2: Deploying Kubernetes at Scale
Mesosphere Inc.
 
PDF
SMACK stack and beyond
Matt Jarvis
 
OSDC 2018 | From batch to pipelines – why Apache Mesos and DC/OS are a soluti...
NETWAYS
 
Elastic data services on Apache Mesos via Mesosphere’s DCOS
harrythewiz
 
Using DC/OS for Continuous Delivery - DevPulseCon 2017
pleia2
 
Webinar: End-to-End CI/CD with GitLab and DC/OS
Mesosphere Inc.
 
Kubernetes One-Click Deployment: Hands-on Workshop (Munich)
QAware GmbH
 
Containerizing couchbase with microservice architecture on mesosphere.pptx
Ravi Yadav
 
Downtime is not an option - day 2 operations - Jörg Schad
Codemotion
 
Modern Container Orchestration (Without Breaking the Bank)
All Things Open
 
Hyperscale Computing, Enterprise Agility with Mesosphere
Markus Eisele
 
DevOps in Age of Kubernetes
Mesosphere Inc.
 
DevOps vs. Site Reliability Engineering (SRE) in Age of Kubernetes
DevOps.com
 
Episode 4: Operating Kubernetes at Scale with DC/OS
Mesosphere Inc.
 
DOD 2016 - Jörg Schad - How Fast Data and Microservices Change the Datacenter.
PROIDEA
 
DCOS Presentation
Jan Repnak
 
Episode 3: Kubernetes and Big Data Services
Mesosphere Inc.
 
Mesos, DC/OS and the Architecture of the New Datacenter
QAware GmbH
 
[DO16] Mesosphere : Microservices meet Fast Data on Azure
de:code 2017
 
Doing Dropbox the Native Cloud Native Way
Minio
 
Episode 2: Deploying Kubernetes at Scale
Mesosphere Inc.
 
SMACK stack and beyond
Matt Jarvis
 
Ad

Recently uploaded (20)

PDF
Fl Studio 24.2.2 Build 4597 Crack for Windows Free Download 2025
faizk77g
 
PDF
Timothy Rottach - Ramp up on AI Use Cases, from Vector Search to AI Agents wi...
AWS Chicago
 
PDF
Newgen 2022-Forrester Newgen TEI_13 05 2022-The-Total-Economic-Impact-Newgen-...
darshakparmar
 
PDF
Smart Trailers 2025 Update with History and Overview
Paul Menig
 
PDF
Agentic AI lifecycle for Enterprise Hyper-Automation
Debmalya Biswas
 
PPTX
"Autonomy of LLM Agents: Current State and Future Prospects", Oles` Petriv
Fwdays
 
PDF
LLMs.txt: Easily Control How AI Crawls Your Site
Keploy
 
PPTX
WooCommerce Workshop: Bring Your Laptop
Laura Hartwig
 
PPTX
Q2 FY26 Tableau User Group Leader Quarterly Call
lward7
 
PDF
Bitcoin for Millennials podcast with Bram, Power Laws of Bitcoin
Stephen Perrenod
 
PPTX
Top iOS App Development Company in the USA for Innovative Apps
SynapseIndia
 
PDF
Chris Elwell Woburn, MA - Passionate About IT Innovation
Chris Elwell Woburn, MA
 
PDF
NewMind AI - Journal 100 Insights After The 100th Issue
NewMind AI
 
PPTX
MSP360 Backup Scheduling and Retention Best Practices.pptx
MSP360
 
PDF
CIFDAQ Token Spotlight for 9th July 2025
CIFDAQ
 
PPT
Interview paper part 3, It is based on Interview Prep
SoumyadeepGhosh39
 
PPTX
UiPath Academic Alliance Educator Panels: Session 2 - Business Analyst Content
DianaGray10
 
PDF
Windsurf Meetup Ottawa 2025-07-12 - Planning Mode at Reliza.pdf
Pavel Shukhman
 
PDF
Using FME to Develop Self-Service CAD Applications for a Major UK Police Force
Safe Software
 
PDF
SFWelly Summer 25 Release Highlights July 2025
Anna Loughnan Colquhoun
 
Fl Studio 24.2.2 Build 4597 Crack for Windows Free Download 2025
faizk77g
 
Timothy Rottach - Ramp up on AI Use Cases, from Vector Search to AI Agents wi...
AWS Chicago
 
Newgen 2022-Forrester Newgen TEI_13 05 2022-The-Total-Economic-Impact-Newgen-...
darshakparmar
 
Smart Trailers 2025 Update with History and Overview
Paul Menig
 
Agentic AI lifecycle for Enterprise Hyper-Automation
Debmalya Biswas
 
"Autonomy of LLM Agents: Current State and Future Prospects", Oles` Petriv
Fwdays
 
LLMs.txt: Easily Control How AI Crawls Your Site
Keploy
 
WooCommerce Workshop: Bring Your Laptop
Laura Hartwig
 
Q2 FY26 Tableau User Group Leader Quarterly Call
lward7
 
Bitcoin for Millennials podcast with Bram, Power Laws of Bitcoin
Stephen Perrenod
 
Top iOS App Development Company in the USA for Innovative Apps
SynapseIndia
 
Chris Elwell Woburn, MA - Passionate About IT Innovation
Chris Elwell Woburn, MA
 
NewMind AI - Journal 100 Insights After The 100th Issue
NewMind AI
 
MSP360 Backup Scheduling and Retention Best Practices.pptx
MSP360
 
CIFDAQ Token Spotlight for 9th July 2025
CIFDAQ
 
Interview paper part 3, It is based on Interview Prep
SoumyadeepGhosh39
 
UiPath Academic Alliance Educator Panels: Session 2 - Business Analyst Content
DianaGray10
 
Windsurf Meetup Ottawa 2025-07-12 - Planning Mode at Reliza.pdf
Pavel Shukhman
 
Using FME to Develop Self-Service CAD Applications for a Major UK Police Force
Safe Software
 
SFWelly Summer 25 Release Highlights July 2025
Anna Loughnan Colquhoun
 

Highly efficient container orchestration and continuous delivery with DC/OS and Jenkins presentation

  • 1. © 2016 Mesosphere, Inc. All Rights Reserved. VELOCITY NYC | SEPTEMBER 20, 2016 CONTINUOUS DELIVERY WITH DC/OS AND JENKINS
  • 2. © 2016 Mesosphere, Inc. All Rights Reserved. SUNIL SHAH Product Manager at Mesosphere @ssk2 ROGER IGNAZIO Tech Lead at Mesosphere @rogerignazio WHO WE ARE
  • 3. © 2016 Mesosphere, Inc. All Rights Reserved. mesosinaction.com Use the code vecymes for 42% off! BUY MY BOOK!
  • 4. © 2016 Mesosphere, Inc. All Rights Reserved. AGENDA Lecture ● Introduction to Apache Mesos and DC/OS ● Components that make up modern infra. ● Running Jenkins as a service on DC/OS ● Continuously deploying applications to DC/OS Demos & Lab ● Installing and configuring Jenkins ● Installing and configuring a load balancer ● Creating a new CI/CD pipeline ● Putting it all together (CD in practice)
  • 5. © 2016 Mesosphere, Inc. All Rights Reserved. DEVELOPER AGILITY, DEFINED
  • 6. © 2016 Mesosphere, Inc. All Rights Reserved. Developer agility empowers developers to ● ship their apps to production ● leverage the power of Mesos and DC/OS ● fix bugs rapidly without downtime! DEVELOPER AGILITY, DEFINED
  • 7. © 2016 Mesosphere, Inc. All Rights Reserved. Continuous integration is not the same as continuous delivery or continuous deployment. DEVELOPER AGILITY, DEFINED
  • 8. © 2016 Mesosphere, Inc. All Rights Reserved. An artifact repo stores built binaries, whereas an image registry stores templates for deployment. DEVELOPER AGILITY, DEFINED
  • 9. © 2016 Mesosphere, Inc. All Rights Reserved. DEVELOPER AGILITY, DEFINED
  • 10. © 2016 Mesosphere, Inc. All Rights Reserved. INTRO TO APACHE MESOS AND DC/OS
  • 11. © 2016 Mesosphere, Inc. All Rights Reserved. A QUICK PRIMER ON CONTAINERS Physical Server Virtual Machine–Based Application Deployment Container–Based Application Deployment Hypervisor OS VM VM OS App App Physical Server Hypervisor OS VM VM OS App App Physical Server Operating System App App Physical Server Operating System App App Mesos Isolate apps by running multiple VMs per physical server; still need to manage each guest OS! Isolate apps using features of the host OS, such as Linux cgroups.
  • 12. © 2016 Mesosphere, Inc. All Rights Reserved. A QUICK PRIMER ON CONTAINERS Linux cgroup Dependencies Linux Host OS Application Docker Container Dependencies Host OS Application Linux cgroupsDocker Containers VM Dependencies Hypervisor Application Virtual Machines Guest OS Docker Engine
  • 13. © 2016 Mesosphere, Inc. All Rights Reserved. A BIT OF CLARIFICATION https://mesos.apache.org https://dcos.io
  • 14. © 2016 Mesosphere, Inc. All Rights Reserved. ● General purpose cluster resource manager ● Represents many machines as a single entity ● Advertises resources directly to frameworks ● Works at scale: Apple, Twitter, Airbnb, Netflix, … WHAT IS MESOS?
  • 15. © 2016 Mesosphere, Inc. All Rights Reserved. ● Two-tier scheduling across resource types ● cpus, mem, disk, and ports by default ● Masters are highly available, agents are fault tolerant ● Checkpointing, agent recovery ● Resource isolation between processes ● Linux cgroups, Docker, … ● Language bindings: C++, Java, Python, Go, … WHAT IS MESOS? (CONTINUED)
  • 16. © 2016 Mesosphere, Inc. All Rights Reserved. MESOS ARCHITECTURE Launch task(s) Mesos Master Quorum Mesos Master (Standby) ZK Mesos Master (Standby) ZK Mesos Master (Leader) ZK Framework B Scheduler Agent 1 Framework A Executor Task(s) Agent n Framework A Executor Task(s) Framework B Executor Task(s) Resource offer Resource offer Framework A Scheduler Launch task(s)
  • 17. © 2016 Mesosphere, Inc. All Rights Reserved. ANATOMY OF A RESOURCE OFFER (TWO-TIER SCHEDULING) Mesos Master(s) Mesos Agent 16 CPUs 128 GB RAM 1 TB disk Mesos Agent 16 CPUs 128 GB RAM 1 TB disk Mesos Agent 16 CPUs 128 GB RAM 1 TB disk Master offers resources to scheduler Scheduler Executor Available compute resources Resource offer accepted, launch executors/tasks Tasks Executor Tasks Executor Tasks Scheduler accepts or declines an offer
  • 18. © 2016 Mesosphere, Inc. All Rights Reserved. ● Service discovery and load balancing ● BIND, Mesos-DNS, Consul-Mesos, Marathon-LB NEW (OLD) PROBLEMS
  • 19. © 2016 Mesosphere, Inc. All Rights Reserved. ● Service discovery and load balancing ● BIND, Mesos-DNS, Consul-Mesos, Marathon-LB ● Monitoring and metrics collection ● Collectd, Nagios, Prometheus, Snap NEW (OLD) PROBLEMS
  • 20. © 2016 Mesosphere, Inc. All Rights Reserved. ● Service discovery and load balancing ● BIND, Mesos-DNS, Consul-Mesos, Marathon-LB ● Monitoring and metrics collection ● Collectd, Nagios, Prometheus, Snap ● Persistent storage (filesystems, databases, etc) ● Ceph, HDFS, Amazon EBS / EFS / S3, NFS, Cassandra NEW (OLD) PROBLEMS
  • 21. © 2016 Mesosphere, Inc. All Rights Reserved. ● Service discovery and load balancing ● BIND, Mesos-DNS, Consul-Mesos, Marathon-LB ● Monitoring and metrics collection ● Collectd, Nagios, Prometheus, Snap ● Persistent storage (filesystems, databases, etc) ● Ceph, HDFS, Amazon EBS / EFS / S3, NFS, Cassandra ● Administration: named URIs vs. ports, IPAM ● Nginx, HAProxy, Mesos-DNS, dhcpd, Minuteman NEW (OLD) PROBLEMS
  • 22. © 2016 Mesosphere, Inc. All Rights Reserved. https://dcos.io https://github.com/dcos DC/OS: BUILT ON MESOS
  • 23. © 2016 Mesosphere, Inc. All Rights Reserved. DC/OS: BUILT ON MESOS
  • 24. © 2016 Mesosphere, Inc. All Rights Reserved. All of the benefits of Mesos, plus ● Built-in service discovery and load balancing ● Support for stateful services ● Turn-key installation of distributed systems ● Cloud-agnostic installer ● Web and command-line interfaces ● All components are integration tested and supported by Mesosphere, Inc. MESOS AND DC/OS: BETTER TOGETHER
  • 25. © 2016 Mesosphere, Inc. All Rights Reserved. JENKINS ON DC/OS
  • 26. © 2016 Mesosphere, Inc. All Rights Reserved. MULTIPLE JENKINS MASTERS Team A Jenkins . . . Jenkins Agent 1 Jenkins Agent 2 . . . Jenkins Agent N Team B Jenkins Jenkins Agent 1 Jenkins Agent 2 . . . Jenkins Agent N Team X Jenkins Jenkins Agent 1 Jenkins Agent 2 . . . Jenkins Agent N
  • 27. © 2016 Mesosphere, Inc. All Rights Reserved. MULTIPLE JENKINS MASTERS → STATIC PARTITIONING Team A Jenkins . . . Jenkins Agent 1 Jenkins Agent 2 . . . Jenkins Agent N Team B Jenkins Jenkins Agent 1 Jenkins Agent 2 . . . Jenkins Agent N Team X Jenkins Jenkins Agent 1 Jenkins Agent 2 . . . Jenkins Agent N 90% Utilized (Normal) 140% Utilized (40 builds in queue) 0% Utilized (Idle)
  • 28. © 2016 Mesosphere, Inc. All Rights Reserved. RUNNING JENKINS ON DC/OS → FAIR SHARING Team A Jenkins . . . DC/OS Agent 1 DC/OS Agent 4 DC/OS Agent N Team B Jenkins DC/OS Agent 2 DC/OS Agent 5 Team X Jenkins DC/OS Agent 3 DC/OS Agent 6 . . . DC/OS
  • 29. © 2016 Mesosphere, Inc. All Rights Reserved. CONTINUOUSLY DEPLOYING APPLICATIONS TO DC/OS
  • 30. © 2016 Mesosphere, Inc. All Rights Reserved. TRADITIONAL RELEASE PROCESS ● Planning & implementing new technologies ● Waiting for people & infrastructure ● Building environment specific CI/CD for each project ● Moving apps from dev to staging to prod DEV(OPS) TEAMS SPEND SIGNIFICANT TIME AND EFFORT ON: PROJECT PLANNING WEEK 1 WEEK 2 WEEK 3 WEEKS 4 TO 8 WEEK 9 CUSTOMER FEEDBACKCONFIGURATIONRESOURCE ALLOCATION Dev Test Stage Release
  • 31. © 2016 Mesosphere, Inc. All Rights Reserved. MODERN RELEASE PROCESS WEEK 1 WEEK 2 WEEK 3 WEEK 4 PROJECT PLANNING CUSTOMER FEEDBACK CUSTOMER FEEDBACK CUSTOMER FEEDBACK RELEASE 1 RELEASE 2 RELEASE 3 RELEASE 4 Better products through a repeatable release cadence Happier customers through continuous feedback Dev Test Stage Release Dev Test Stage Release Dev Test Stage Release Dev Test Stage Release
  • 32. © 2016 Mesosphere, Inc. All Rights Reserved. ● Scheduling — advertising available compute resources ● Deployments — getting an application onto a node ● Health checks — ensuring the app/service is healthy ● Service discovery — connecting to dependent services ● Persistence — running stateful services in containers DEPLOYING APPLICATIONS: BASIC REQUIREMENTS
  • 33. © 2016 Mesosphere, Inc. All Rights Reserved. A sysadmin provisions one or more physical/virtual servers to host the app Mesos resource offers (two-tier scheduling) offers available resources directly to frameworks DEPLOYING APPLICATIONS: SCHEDULING Before DC/OS With DC/OS
  • 34. © 2016 Mesosphere, Inc. All Rights Reserved. By hand or using Puppet / Chef / Ansible Jenkins SSHing to the machine and running a shell script Note: all dependencies must also be present! Marathon deploys containers, ideally using a CI/CD tool to create/update app definitions Docker containers packages app and dependencies DEPLOYING APPLICATIONS: DEPLOYMENTS Before DC/OS With DC/OS
  • 35. © 2016 Mesosphere, Inc. All Rights Reserved. Nagios pages a sysadmin Marathon performs health checks, restarts unhealthy/failed instances DEPLOYING APPLICATIONS: HEALTH CHECKS Before DC/OS With DC/OS
  • 36. © 2016 Mesosphere, Inc. All Rights Reserved. Static hostnames / IP addresses in a spreadsheet or config management A sysadmin configures a load balancer manually or with Puppet / Chef / Ansible Mesos-DNS provides DNS resolution for running services (hostname / IP address, ports, etc) Load balancer configs built dynamically using cluster state DEPLOYING APPLICATIONS: SERVICE DISCOVERY Before DC/OS With DC/OS
  • 37. © 2016 Mesosphere, Inc. All Rights Reserved. Individual servers with RAID 1/5/6/10, expensive SANs, NFS, etc. Dedicated, statically partitioned Ceph or Gluster storage clusters Mesos external/persistent volumes (REX-Ray), HDFS, etc. Self-healing Ceph or Gluster on Mesos / DC/OS DEPLOYING APPLICATIONS: PERSISTENCE Before DC/OS With DC/OS
  • 38. © 2016 Mesosphere, Inc. All Rights Reserved. Q: Given that we are all engineers, which tools would we like to work with?
  • 39. © 2016 Mesosphere, Inc. All Rights Reserved. DEMOS & LAB
  • 40. © 2016 Mesosphere, Inc. All Rights Reserved. 40 PIPELINE COMPONENTS Continuous Integration Container Registry Container Orchestrator Version Control System Load Balancer Production Environment Continuous Delivery Pipeline git push DC/OS
  • 41. © 2016 Mesosphere, Inc. All Rights Reserved. 41 PIPELINE COMPONENTS Jenkins DockerHub MarathonGitHub Marathon-lbMesos Continuous Delivery Pipeline git push DC/OS
  • 42. © 2016 Mesosphere, Inc. All Rights Reserved. 42 PIPELINE CONFIGURATION Jenkinsfile Dockerfile marathon.json Continuous Delivery Pipeline git push DC/OS
  • 43. © 2016 Mesosphere, Inc. All Rights Reserved. A SNEAK PREVIEW
  • 44. © 2016 Mesosphere, Inc. All Rights Reserved. ● Head over to github.com/mesosphere/vny ● Follow the exercises! ● Use the username/password: velocityuser/velocitypassword YOUR TURN
  • 45. © 2016 Mesosphere, Inc. All Rights Reserved. Roger Ignazio [email protected] @rogerignazio Sunil Shah [email protected] @ssk2 THANK YOU! Learn more by visiting DCOS.io and Mesosphere.com