+ All Categories
Home > Documents > Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies [email protected]...

Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies [email protected]...

Date post: 26-Jun-2020
Category:
Upload: others
View: 3 times
Download: 0 times
Share this document with a friend
81
Luke Kanies [email protected] Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday, February 15, 2011
Transcript
Page 1: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Luke [email protected], Puppet Labs

Portland, OregonUSA

Puppet: Infrastructure

as Code

Tuesday, February 15, 2011

Page 2: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

How Puppet Works

Define: !"#$%&'(()#*+%,)-./0/#"1)%% ./23'/3)%45'%,)+"32%/%30/($%56%0)./#"52+$"(+%7)#8))2%0)+5'0-)+%8"#$"2%0)'+/7.)%95,'.)+:%;$)+)%95,'.)+%,)6"2)%45'0%"260/+#0'-#'0)%"2%"#+%,)+"0),%+#/#):

1

Simulate:%!"#$%#$"+%0)+5'0-)%% 30/($<%&'(()#%"+%'2"=')%"2%"#+%/7"."#4%#5%+"9'./#)%,)(.549)2#+<%)2/7."23%45'%#5%#)+#%-$/23)+%8"#$5'#%,"+0'(#"52%#5%45'0%"260/+#0'-#'0):

2

% Enforce:%&'(()#%-59(/0)+%45'0%% +4+#)9%#5%#$)%,)+"0),%+#/#)%/+%45'%,)6"2)%"#<%/2,%/'#59/#"-/..4%)2650-)+%"#%#5%#$)%,)+"0),%+#/#)%)2+'0"23%45'0%+4+#)9%"+%"2%-59(."/2-):

3

% Report: &'(()#%>/+$75/0,%0)(50#+%% #0/-?%0)./#"52+$"(+%7)#8))2%-59(52)2#+%/2,%/..%-$/23)+<%/..58"23%45'%#5%?))(%'(%8"#$%+)-'0"#4%/2,%-59(."/2-)%9/2,/#)+:%@2,%8"#$%#$)%5()2%@&A%45'%-/2%"2#)30/#)%&'(()#%8"#$%#$"0,%(/0#4%952"#50"23%#55.+:

4

>BCADB>C;@;B

EFDDBG;C;@;B

A;BD@;B%@G>%AGEDB@

CB%EHIBD@

JB

Tuesday, February 15, 2011

Page 3: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

SSH0Tuesday, February 15, 2011

Page 4: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Puppet Is Pervasive

Financial

TechnologyEntertainmentWeb

Defense

Tuesday, February 15, 2011

Page 5: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

GPL, written in Ruby

Tuesday, February 15, 2011

Page 6: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Why does Puppet exist?

Tuesday, February 15, 2011

Page 7: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Embarrassment

Tuesday, February 15, 2011

Page 8: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

FearTuesday, February 15, 2011

Page 9: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Somebody has to do something, and it's just incredibly pathetic that it has to be us. -- Jerry Garcia

Tuesday, February 15, 2011

Page 10: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Why didn’t someone else make it?

Tuesday, February 15, 2011

Page 11: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Sysadmins do too much

Image from http://flickr.com/photos/shirleytwofeathers/2068713495/Tuesday, February 15, 2011

Page 12: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Image from http://flickr.com/photos/kenskritters/2128853769/

Speciation

Tuesday, February 15, 2011

Page 13: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Sysadmins know too much

Tuesday, February 15, 2011

Page 14: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Programming SysAdmin

Low-level, non-portable

Assembly commands and files

Abstract, portable

C* Resources

Shell scripts are infrastructure assembly code

* For small values of abstract

Tuesday, February 15, 2011

Page 15: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

It’s not about fewer sysadmins

Tuesday, February 15, 2011

Page 16: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Would your boss pick:

Tuesday, February 15, 2011

Page 17: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Would your boss pick:

•The current service quality at a lower price?

Tuesday, February 15, 2011

Page 18: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Would your boss pick:

•The current service quality at a lower price?

•A higher service quality at the current price?

Tuesday, February 15, 2011

Page 19: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Let’s talk about you

Tuesday, February 15, 2011

Page 20: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Some questions

Tuesday, February 15, 2011

Page 21: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Some questions

•How many of you have written software to manage computers?

Tuesday, February 15, 2011

Page 22: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Some questions

•How many of you have written software to manage computers?

•How many have published this software?

Tuesday, February 15, 2011

Page 23: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Developer Sysadmin

Three people

Tuesday, February 15, 2011

Page 24: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Puppet allows you to bridge that gap

Image from http://www.flickr.com/photos/patrick-smith-photography/2969769911/sizes/o/

#devops

Tuesday, February 15, 2011

Page 25: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Either you can manage many machines with little

effort

Tuesday, February 15, 2011

Page 26: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Either you can manage many machines with little

effort

Or you can’t

Tuesday, February 15, 2011

Page 27: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Model-driven Management

Tuesday, February 15, 2011

Page 28: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Resource Abstraction Layer (RAL)

Tuesday, February 15, 2011

Page 29: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Do you really care how rpm works?

Tuesday, February 15, 2011

Page 30: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Resource Providers

• 29 package types

• Users in NetInfo, useradd, pw

• Builtin support for RHEL, OS X, Solaris, Debian, Ubuntu, Gentoo, SuSE, FreeBSD, and more

Tuesday, February 15, 2011

Page 31: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Your infrastructure is code

Tuesday, February 15, 2011

Page 32: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Code is compiledinto a catalog

Tuesday, February 15, 2011

Page 33: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

The client gets a catalog, not code

Tuesday, February 15, 2011

Page 34: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Least Privilege isin the house

Tuesday, February 15, 2011

Page 35: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

If it’s not in the catalog, it’s not

managed

Tuesday, February 15, 2011

Page 36: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

If it’s not in the catalog, it can’t affect the

system

Tuesday, February 15, 2011

Page 37: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Compiled Catalogsare a DAG

"Exec[createrepo-PM-RHEL5-noarch]"

"Yumrepo[PM-RHEL5-x86_64]"

"Yumrepo[PM-RHEL5-noarch]"

"Package[postgresql-server]"

"Package[thttpd]"

"File[/var/www/thttpd/html/yum-PM-RHEL5-noarch]""File[/var/www/thttpd/html/yum-PM-RHEL5-x86_64]"

"Exec[rsync-rpmdir-PM-RHEL5-x86_64]"

"Exec[createrepo-PM-RHEL5-x86_64]"

"Postgres::Role[puppet]"

"Exec[rsync-rpmdir-PM-RHEL5-noarch]"

Tuesday, February 15, 2011

Page 38: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

The model gives you more data and more

guarantees

Tuesday, February 15, 2011

Page 39: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Is this file being managed by Puppet?

Tuesday, February 15, 2011

Page 40: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Which services will I need to restart if I edit

this file?

Tuesday, February 15, 2011

Page 41: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Who requires this package?

Tuesday, February 15, 2011

Page 42: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Classes are modeled

Tuesday, February 15, 2011

Page 43: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Code or Data?

Tuesday, February 15, 2011

Page 44: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Multi Node

Use Puppet to create composable configurations and manage the enterprise infrastructure

Define relationships between resources. ! "#$%!&'(()$*!+,'!-).#/)!+,'0!1,-'2)3!4+!/,-)!52633#.#56$#,/3*!3'5%!63!")4!7)08)0!,0!96$6463)*!622,:#/;!+,'!$,!-).#/)!0)26$#,/3%#(3!4)$:))/!0)3,'05)3!6/-!5,/.#;'0)!$%,'36/-3!,.!3)08)03!6$!,/5)<!

1

Assign resource relationships automatically.!! =,'!56/!$%)/!633#;/!6/-!-)(2,+!5,/.#;'06$#,/3!8#6!&'(()$!963%4,60-*!,0!:#$%!+,'0!,:/!5'3$,1#>)-!?@9A!$,,23<

Via Puppet Dashboard

CustomExternal Source

(CMDB, LDAP, etc.)

2

Reusable, composable configurations. !! "#$%!&'(()$!+,'!56/!0)B'3)!1,-'2)3!650,33!1'2$#(2)!/,-)3*!#/!:%6$)8)0!5,14#/6$#,/!+,'!/))-*!0)-'5#/;!0)()$#$#8)!$63C3!6/-!)2#1#/6$#/;!)00,0B(0,/)!350#($3<!

3

9DEDAD7F "FA!7FGHFG D&&!7FGHFG 7F?IGJE=

"FA!7=7EF@7 9DEDAD7F!7=7EF@7 D&&KJ?DEJLM!7=7EF@7

ML9F

ML9F ML9F

ML9F ML9F

ML9F

Tuesday, February 15, 2011

Page 45: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Puppet is Idempotent

Tuesday, February 15, 2011

Page 46: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Puppet is Idempotent

Tuesday, February 15, 2011

Page 47: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Puppet Platform

MCollectivehandlessequencing

Puppet Master

Puppet Dashboard

Puppet AgentFacter

Node 3rd Party Systems

Puppet Module Forge

Modules

Tuesday, February 15, 2011

Page 48: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

How Puppet Manages Data Flow for Individual Nodes

Facts!"#$%&'#$(#%'($%&)*+,-.#'$'+/+$+0&1/$-/(#,2$/&$/"#$3144#/$5+(/#)6

1

Catalog3144#/$1(#($/"#$7+8/($/&8&*4-,#$+$9+/+,&:$/"+/(4#8-2-#($"&;$/"#$%&'#("&1,'$0#$8&%2-:1)#'6

2

Report8+%$+,(&$(#%'$'+/+$/&$/"-)'$4+)/<$/&&,(6

4

Report!"#$%&'#$)#4&)/($0+8=$/&$3144#/$-%'-8+/-%:$/"#$8&%2-:1)+/-&%$-($8&*4,#/#>$;"-8"$-($?-(-0,#$-%$/"#$3144#/$@+("0&+)'6

3

Report CollectorA3144#/$&)$B)'$4+)/<$/&&,C

Node

PuppetMaster

SSL secure encryption on all data transport

Tuesday, February 15, 2011

Page 49: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Uses SSL, and provides a Certificate Authority

Image from http://www.flickr.com/photos/piet_musterd/2307596484/sizes/l/Tuesday, February 15, 2011

Page 51: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

How to use Puppet

The strategic version

Tuesday, February 15, 2011

Page 52: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Seek the pain

Image from http://www.flickr.com/photos/pagedooley/2147718252/sizes/l/Tuesday, February 15, 2011

Page 53: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Solve the simple problems

Tuesday, February 15, 2011

Page 54: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Add the infrastructure features you always

wanted

Tuesday, February 15, 2011

Page 55: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

How to use PuppetThe tactical version

Tuesday, February 15, 2011

Page 56: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Think like Puppet thinks

Tuesday, February 15, 2011

Page 57: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Think like Puppet thinks

• Resources, not text snippets or lines added to files

Tuesday, February 15, 2011

Page 58: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Think like Puppet thinks

• Resources, not text snippets or lines added to files

• What resources are you managing?

Tuesday, February 15, 2011

Page 59: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Think like Puppet thinks

• Resources, not text snippets or lines added to files

• What resources are you managing?

• How are they related to each other?

Tuesday, February 15, 2011

Page 60: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Replace Shell Scripts with Resources

Becomes:

This:

Tuesday, February 15, 2011

Page 61: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Replace Shell Scripts with Resources

Becomes:

This:

Tuesday, February 15, 2011

Page 62: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Replace Shell Scripts with Resources

Becomes:

This:

Tuesday, February 15, 2011

Page 63: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Replace Shell Scripts with Resources

Becomes:

This:

Tuesday, February 15, 2011

Page 64: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Relationships matter but are often implicit

Package

Service

Service should restart whenconfiguration changesConfiguration

Configuration should get modifed after package installation

Tuesday, February 15, 2011

Page 65: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Explicit Relationships

Tuesday, February 15, 2011

Page 66: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Relationships provide ordering and notification

"Exec[createrepo-PM-RHEL5-noarch]"

"Yumrepo[PM-RHEL5-x86_64]"

"Yumrepo[PM-RHEL5-noarch]"

"Package[postgresql-server]"

"Package[thttpd]"

"File[/var/www/thttpd/html/yum-PM-RHEL5-noarch]""File[/var/www/thttpd/html/yum-PM-RHEL5-x86_64]"

"Exec[rsync-rpmdir-PM-RHEL5-x86_64]"

"Exec[createrepo-PM-RHEL5-x86_64]"

"Postgres::Role[puppet]"

"Exec[rsync-rpmdir-PM-RHEL5-noarch]"

Tuesday, February 15, 2011

Page 67: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Classes document Intent

Tuesday, February 15, 2011

Page 68: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Organize files into modules

Tuesday, February 15, 2011

Page 69: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Provide platform abstraction

Debian

Red Hat

Tuesday, February 15, 2011

Page 70: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Provide platform abstraction

Debian

Red Hat

Tuesday, February 15, 2011

Page 71: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Portability and Naming

Tuesday, February 15, 2011

Page 72: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Class Membership

Tuesday, February 15, 2011

Page 73: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Class Membership

Tuesday, February 15, 2011

Page 74: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Puppet in the cloud

Tuesday, February 15, 2011

Page 75: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Heavily used in EC2, VMWare, Xen, etc

Tuesday, February 15, 2011

Page 76: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Golden Image or Foil Ball?

Image from http://www.flickr.com/photos/fungep/2516767121/sizes/l_

Tuesday, February 15, 2011

Page 77: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

pulabs

ppetThe people behind

Puppet

Tuesday, February 15, 2011

Page 78: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Bad product,hungry Luke

Tuesday, February 15, 2011

Page 79: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

From 3 to 32 people in 18 months

Tuesday, February 15, 2011

Page 80: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

Just launchedPuppet Enterprise

Tuesday, February 15, 2011

Page 81: Puppet: Infrastructure as Code - IT Pro Forum · 15-02-2011  · Luke Kanies luke@puppetlabs.com Founder, Puppet Labs Portland, Oregon USA Puppet: Infrastructure as Code Tuesday,

pulabs

ppet

Questions?Tuesday, February 15, 2011


Recommended