ci for the world - agile 2011

45
Continuous Integration for the world Tuesday 6 September 2011

Upload: patrick-debois

Post on 16-May-2015

12.232 views

Category:

Technology


1 download

TRANSCRIPT

Page 1: CI for the world - Agile 2011

Continuous Integration for the world

Tuesday 6 September 2011

Page 2: CI for the world - Agile 2011

Agile Code &

Agile Infrastructure

Tuesday 6 September 2011

Page 3: CI for the world - Agile 2011

Caveat: Your brain might hurt after this session

Tuesday 6 September 2011

Page 4: CI for the world - Agile 2011

Patrick Debois

• Belgium

• @patrickdebois

• http://jedi.be/blog & http://cutter.com

• Organizer of devopsdays

Tuesday 6 September 2011

Page 5: CI for the world - Agile 2011

Julian Simpson

• New Zealand/UK

• @builddoctor

• http://www.build-doctor.com/

Tuesday 6 September 2011

Page 6: CI for the world - Agile 2011

Tuesday 6 September 2011

Page 8: CI for the world - Agile 2011

Infrastructure as code

Tuesday 6 September 2011

Page 9: CI for the world - Agile 2011

(virtual)server

application

configuration mgt

fabric

ruby,java,...

puppet,chef,...

xen,vmware,...

operating system linux, windows,..

lb,storage,firewall

Tuesday 6 September 2011

Page 10: CI for the world - Agile 2011

Just EnoughOperating System

Tuesday 6 September 2011

Page 11: CI for the world - Agile 2011

Veewee demo

https://github.com/jedi4ever/veewee

http://www.youtube.com/watch?v=gR28-aHX_nU

Tuesday 6 September 2011

Page 12: CI for the world - Agile 2011

**! What just happened?

Tuesday 6 September 2011

Page 13: CI for the world - Agile 2011

Definition.rb

Postinstall.sh

Preseed.cfg

Ubuntu.iso

Build

VirtualMachine

JEOS

SOURCE BINARY

Chef/PuppetRuby

Te

st BINARY

Package

Lucid64.box

Tuesday 6 September 2011

Page 14: CI for the world - Agile 2011

Version Control

Tuesday 6 September 2011

Page 15: CI for the world - Agile 2011

Archiving Artefacts

Tuesday 6 September 2011

Page 16: CI for the world - Agile 2011

Tuesday 6 September 2011

Page 17: CI for the world - Agile 2011

Vagrant demo

http://vagrantup.com/

http://www.youtube.com/watch?v=O_FiL1yb6_s

Tuesday 6 September 2011

Page 18: CI for the world - Agile 2011

It works on my machine syndrome

Tuesday 6 September 2011

Page 19: CI for the world - Agile 2011

Configuration Mgmt

http://www.opscode.com/ http://www.puppetlabs.com/

Tuesday 6 September 2011

Page 20: CI for the world - Agile 2011

No more ‘Bob’ Directory

Tuesday 6 September 2011

Page 21: CI for the world - Agile 2011

Idempotent

Tuesday 6 September 2011

Page 23: CI for the world - Agile 2011

1 include_recipe "apache2" 2 3 template "/var/www/index.html" do 4 owner "www-data" 5 group "www-data" 6 source "index_page.erb" 7 mode 0644 8 end

Recipe (simple APP = 1 web page)

Tuesday 6 September 2011

Page 24: CI for the world - Agile 2011

$ cat chefrepo/site-cookbooks/onepage/templates/default/index_page.erb

I am <%= node[:onepage][:name] %>

Tuesday 6 September 2011

Page 25: CI for the world - Agile 2011

51 config.vm.provision :chef_solo do |chef| 52 chef.cookbooks_path = [

"chefrepo/cookbooks", "chefrepo/site-cookbooks"]

53 chef.add_recipe "apache2" 54 chef.add_recipe "onepage" 55 chef.json.merge!(

{:onepage => {:name => "masterof my app."}})

56 end

Tuesday 6 September 2011

Page 26: CI for the world - Agile 2011

Chef Demo

http://www.youtube.com/watch?v=XRvhXLOKerQ

Tuesday 6 September 2011

Page 27: CI for the world - Agile 2011

Code smellsServer smells

Tuesday 6 September 2011

Page 28: CI for the world - Agile 2011

SSH Login considered harmful

Tuesday 6 September 2011

Page 29: CI for the world - Agile 2011

IDE’s

https://github.com/cloudsmith/gepetto

http://reactor8.com/

Tuesday 6 September 2011

Page 30: CI for the world - Agile 2011

Disposable Infrastructure

Tuesday 6 September 2011

Page 31: CI for the world - Agile 2011

Re-build vs Patching

Tuesday 6 September 2011

Page 32: CI for the world - Agile 2011

Cucumber Nagios Demo

http://auxesis.github.com/cucumber-nagios/

http://www.youtube.com/watch?v=b5RwnuIEaJI

Tuesday 6 September 2011

Page 33: CI for the world - Agile 2011

Feature: DemonstrationIn order to demonstrate cucumber nagiosAs a presenter at Agile 2011I want to test some text on a page

Scenario: Find some text on a page  When I go to "http://192.168.0.1:4567/"Then I should see "^I am .+"

Tuesday 6 September 2011

Page 34: CI for the world - Agile 2011

**! What just happened?

Tuesday 6 September 2011

Page 35: CI for the world - Agile 2011

Build

VirtualMachine

JEOS

SOURCE BINARY

Chef/PuppetRuby

Te

st BINARY

Package

Lucid64.box

Cookbook

APP

Vagrantfile

APP CODE

Tuesday 6 September 2011

Page 36: CI for the world - Agile 2011

A shared languagehelps in understanding

each other

Tuesday 6 September 2011

Page 37: CI for the world - Agile 2011

Pairingadmins + devs

Tuesday 6 September 2011

Page 38: CI for the world - Agile 2011

Mccloud demohttp://www.youtube.com/watch?v=2ixTk4Uj23c

https://github.com/jedi4ever/mccloud/

Tuesday 6 September 2011

Page 39: CI for the world - Agile 2011

**! What just happened?

Tuesday 6 September 2011

Page 40: CI for the world - Agile 2011

Re-UseTools/Code

Across Envinronments

Tuesday 6 September 2011

Page 41: CI for the world - Agile 2011

DecreaseSetup-TimeCycle-Time

Tuesday 6 September 2011

Page 42: CI for the world - Agile 2011

applicationapplication deploy

source package

externalrepo

download

internalrepoinstall

*.java

*.war

compiled*.class *.jar

compile

testlibrary

test

source package*.java

compiled*.class *.jar

compile library

test

source package*.java

compiled*.class

compile

test

install

externalrepo

download

internalrepo

*.iso*.rpm

jeos

config mgmt tool

os provision

middlewaresourcerecipes cookbooks

library

runtime

(virtual) server

testpackage

source

ami,box

imageste

stpackagepxe installedbase vmpreseed

bootstrap

*.ami

*.ova

test

test

bootstrap install

*.jar

configuration mgt

(cloud) infrastructure

cloudformation

sourcefabric provision

jvm

pkg,config, ...

source imagesinstalled*.jar

init.d*.rpm

orchestration

Tuesday 6 September 2011

Page 43: CI for the world - Agile 2011

fog(ruby)

boto (python)

jclouds (java)

cfengine

chef

amazon

rackspace

xen

kvm

lxc

vcloud

virtualbox

fusion

vm player

vsphere

PublicCloud

PrivateCloud

LaptopCloud

libvirt

API’s

Compute

Storage

Network

CloudAbstraction

library

API’s

Just EnoughOperating System

‘Private’Cloud Abstraction library

...

...

...

Just EnoughInfrastructure Code

vagrant

mccloud CLI’s

CLI’s

veeweeJust Enough

Image Building

puppet

rundesk

deployinator

pie Just EnoughCoordination

Tuesday 6 September 2011

Page 44: CI for the world - Agile 2011

Production beginsin Development

Tuesday 6 September 2011

Page 45: CI for the world - Agile 2011

Thank you!

Tuesday 6 September 2011