continuous testing using shippable and docker

Post on 07-Jan-2017

4.171 Views

Category:

Technology

3 Downloads

Preview:

Click to see full reader

TRANSCRIPT

@muktaa

DevOps@WhiteHedge.com

Continuous Testing using Shippable and Docker

Mukta AphaleDevOps Practice Head

WhiteHedge Technologies

@muktaa

DevOps@WhiteHedge.com

About Me• C, Java, Ruby developer for about 12 years•DevOps and Systems enthusiast since 3 years• Creative at heart, technology geek at profession• Technology, innovation and the thirst to keep learning are what define me•Working as DevOps Head at WhiteHedge Technologies• Love to travel, read and write

@muktaa

DevOps@WhiteHedge.com

About WhiteHedge Technologies

@muktaa

DevOps@WhiteHedge.com

Typical DevOps Phases•Continuous Integration•Continuous Delivery•Continuous Testing•Continuous Monitoring

@muktaa

DevOps@WhiteHedge.com

The Environments

Diagram Credit: https://sdarchitect.files.wordpress.com/2012/10/cicdctcm.png

@muktaa

DevOps@WhiteHedge.com

Is Continuous Testing really just one phase in DevOps?

@muktaa

DevOps@WhiteHedge.com

DevOps is actually all about Continuous Testing!

@muktaa

DevOps@WhiteHedge.com

The Love Triangle•DevOps = Marriage of Development and Operations•Where does the Testing Team fit in the definition?• Testing teams need to assert themselves to fit in all phases of DevOps

@muktaa

DevOps@WhiteHedge.com

Testing in all phases

• Pre-flight testing•Unit Testing• Functional Testing• Integration Testing•Nightly and Weekend Regression Tests

Test Early.Test Faster.Test Often.Automate.

@muktaa

DevOps@WhiteHedge.com

Testing Maturity• Key differentiator of best devops infrastructures• Vital part of devops process• Test orchestration and automation is still a challenge• Verify the changes. Verify them fast.• Test code changes and if they integrate them well• Ensure changes do not blow up the product!

Credit: http://devops.com/2015/02/02/devops-continuous-testing/

@muktaa

DevOps@WhiteHedge.com

The ChallengeEarly, Frequent and Accurate Testing requires access to real world testing environments.

Service Virtualization in the form of Containerization, specifically using Docker,

intends to solve this problem.

@muktaa

DevOps@WhiteHedge.com

What is Docker?

Linux Container3 Components:Docker Engine

Docker HubDocker Images

Benefits:Speed

PortabilityDensity

Open Source

“Can create lightweight, self sufficient containers from

any application”

@muktaa

DevOps@WhiteHedge.com

Virtual Machine Docker

Docker is not a VM

@muktaa

DevOps@WhiteHedge.com

Typical Design

CI – Build and Unit Testing

Nightly Builds – Build, Unit Test and Deploy to QA Env

Run Integration Tests (Selenium

Tests)

Feedback – Email Test Report

Failing Tests Polluted the Env. Even after

successful tests, the env was changed.

For every deployment, the Env

has to be setup

@muktaa

DevOps@WhiteHedge.com

After Dockerizing…

Dockerfile (app1)Dockerfile (app2)Dockerfile (db)

Docker HubBase-Image-App1Base-Image-App2Base-Image-DB

CIServer

Deployment Script

Test Environment:

App1 App2

DB

Selenium Tests

Feedback – Email Test

Report

@muktaa

DevOps@WhiteHedge.com

Shippable makes this docker deployment and

thus testing, simple

@muktaa

DevOps@WhiteHedge.com

Shippable•SaaS Platform•Reduces the time taken for code to be built, tested and deployed to production•Shippable CI/CD•Shippable Formations

@muktaa

DevOps@WhiteHedge.com

Automated Deployment Pipelines

@muktaa

DevOps@WhiteHedge.com

@muktaa

DevOps@WhiteHedge.com

@muktaa

DevOps@WhiteHedge.com

@muktaa

DevOps@WhiteHedge.com

Shippable Formations• Easy way to provision, configure, and deploy multi-

container Dev and Test clouds (environments)• Fully integrated with the updated Shippable CI/CD

platform, and together, they create an automated, frictionless pipeline from source control to full-topology environments• Can mimic your production environment or represent

any combination of software component versions you'd like to deploy.

@muktaa

DevOps@WhiteHedge.com

Shippable Formations (Contd.)Fully orchestrated, persistent, and 'smart', i.e. they can automatically update themselves when any new code is committed into any component of the application. 

Ensures that your Dev and Test labs always run the latest code and are reliable indicators of how that code will behave in production.

@muktaa

DevOps@WhiteHedge.com

Creating Formations

@muktaa

DevOps@WhiteHedge.com

@muktaa

DevOps@WhiteHedge.com

Notice the services under each env, the docker image and how it is mapped.

@muktaa

DevOps@WhiteHedge.com

Status of deployment of services on each environments

@muktaa

DevOps@WhiteHedge.com

Environment Variables can be set as a part of configuration

@muktaa

DevOps@WhiteHedge.com

Image details and the associated configurations

@muktaa

DevOps@WhiteHedge.com

Why Formations?• Automation without scripts• Automated integration/functional testing•One-click upgrade and rollback•No more 'works on my machine' bugs•Developer-focused approach • Cost effective

@muktaa

DevOps@WhiteHedge.com

LighthouseIt is a docker image watcher. You can add any image from any registry that you want to track and get notified via email when there is an update.

@muktaa

DevOps@WhiteHedge.com

Interesting Facts about Shippable• Shippable was founded in 2013 by Avi Cavale and Manisha

Sahasrabuddhe• It was known as Qhode initially• Avi managed to raised the first round of funding over a game of table

tennis!• Shippable has raised over $10 million funding till today• Formations was launched on 18 June 2015• Shippable runs more than 60,000 containers weekly• Google Kubernetes can do 150-200 daily builds using Shippable• Shippable calls itself to be in the era of DevOps 2.0, meaning developers

no longer have to write code and scripts in unfamiliar languages to make deployments

@muktaa

DevOps@WhiteHedge.com

Thank You!Questions?

We are Authorized Docker Training Partners in the APAC region!

You can write to us at devops@whitehedge.com for details about Certified Docker Training.

top related