[celix] scaling devops with puppet and perforce

34
1 Scaling DevOps with Puppet and Perforce Christoph Leithner Founder CELIX Hard- & Software VertriebsgmbH http://www.celix.at Logo area

Upload: perforce

Post on 11-May-2015

997 views

Category:

Technology


2 download

DESCRIPTION

Learn how to scale DevOps to a large number of IT services and take the next step towards end-to-end agility. In this presentation, see how Perforce and Git Fusion can help manage Puppet environments with an increasing number of Puppet modules.

TRANSCRIPT

Page 1: [Celix] Scaling DevOps with Puppet and Perforce

1

Scaling DevOps with Puppet and Perforce

Christoph Leithner

Founder

CELIX Hard- & Software

VertriebsgmbH

http://www.celix.at

Logo area

Page 2: [Celix] Scaling DevOps with Puppet and Perforce

2

Agenda

• What is DevOps?

• IT Automation with Puppet

• Scaling DevOps with Perforce

• Agile Flow of Change for Puppet Modules

Page 3: [Celix] Scaling DevOps with Puppet and Perforce

3

What is DevOps?

Page 4: [Celix] Scaling DevOps with Puppet and Perforce

4

DevOps

What is DevOps?

Source: http://commons.wikimedia.org/wiki/File:Devops.png by Rajiv Pan

Technology

Operations

DevOps

Page 5: [Celix] Scaling DevOps with Puppet and Perforce

5

Area 1: Extend delivery to production

DEV OPS

Area 2: Extend operations feedback to project

Area 3: Embed project knowledge into operations

Area 4: Embed operations knowledge into project

Source: http://www.jedi.be/blog/2012/05/12/codifying-devops-area-practices/ by Patrick Debois

DevOps Areas - codified by Patrick Debois

Page 6: [Celix] Scaling DevOps with Puppet and Perforce

6

• IT Automation: Puppet

• Shared Version Control: Perforce

• Build and Deploy: Atlassian Bamboo

• Process Management: Atlassian JIRA

DevOps Tools - Overview

Page 7: [Celix] Scaling DevOps with Puppet and Perforce

7

IT Automation with Puppet

Page 8: [Celix] Scaling DevOps with Puppet and Perforce

8

Define. 1 2 Simulate.

3 Enforce.

4 Report.

How Puppet works

Page 9: [Celix] Scaling DevOps with Puppet and Perforce

9

Database Web Server Application Server Security Mo

du

les

Via Puppet Dashboard Custom External Source (CMDB, LDAP, etc.)

Define your

resources in

modules.

1

Assign resource

relationships

automatically.

2

Reuseable,

composable

configurations.

3

Web Servers Database Servers Application Servers

Define Composable Deployments with Puppet

Page 10: [Celix] Scaling DevOps with Puppet and Perforce

10

user { 'dave':

ensure => present,

uid => '507',

gid => 'admin',

shell => '/bin/zsh',

home => '/home/dave',

managehome => true,

}

Puppet Resource Abstraction Layer (RAL)

Page 11: [Celix] Scaling DevOps with Puppet and Perforce

11

class ssh {

package { ‘ssh’:

ensure => latest,

}

file { ‘/etc/ssh/sshd_config’:

source => ‘puppet:///modules/ssh/sshd_config’,

}

service { ‘sshd’:

ensure => running,

}

Package[‘ssh’]->File[‘/etc/ssh/sshd_config’]~>Service[‘sshd’]

Package[‘ssh’]~>Service[‘sshd’]

}

class ssh Puppet RAL Example:

Page 12: [Celix] Scaling DevOps with Puppet and Perforce

12

module_name

manifests

files

templates

lib

spec

tests

Modulefile

Puppet Modules – Deployments as Code

Page 13: [Celix] Scaling DevOps with Puppet and Perforce

13

name 'puppetlabs-apache'

version '0.6.0'

source 'git://github.com/puppetlabs/puppetlabs-apache.git'

author 'puppetlabs'

license 'Apache 2.0'

summary 'Puppet module for Apache'

description 'Module for Apache configuration'

project_page 'https://github.com/puppetlabs/puppetlabs-apache'

## Add dependencies, if any:

dependency 'puppetlabs/firewall', '>= 0.0.4'

dependency 'puppetlabs/stdlib', '>= 2.2.1'

Puppet Modulefile for puppetlabs-apache

Page 14: [Celix] Scaling DevOps with Puppet and Perforce

14

http://forge.puppetlabs.com

Page 15: [Celix] Scaling DevOps with Puppet and Perforce

15

puppet module install puppetlabs-apache --version 0.6.0

firewall

stdlib

apache

Puppet Module Subcommand

Page 16: [Celix] Scaling DevOps with Puppet and Perforce

16

puppet module install puppetlabs-ntp --version 0.2.0

puppet module install puppetlabs-apache --version 0.6.0

firewall

ntp

stdlib

apache

Sets of Modules

Page 17: [Celix] Scaling DevOps with Puppet and Perforce

17

puppet module install puppetlabs-ntp --version 0.2.0

puppet module install puppetlabs-apache --version 0.6.0

firewall

Puppet Environment

ntp

stdlib

apache

Multiple Environments on a single Puppet Master

Sets of Modules – Puppet Environments

Page 18: [Celix] Scaling DevOps with Puppet and Perforce

18

Option A: Version each Module you need to change locally

A Git Repository for each Puppet Module you change

firewall

Puppet Environment

ntp

stdlib

apache

Versioning Puppet Modules/Environments

Page 19: [Celix] Scaling DevOps with Puppet and Perforce

19

Option B: Version the Environment Folder

A single Git Repository for the Puppet Environment

firewall

Puppet Environment

ntp

stdlib

apache

Versioning Puppet Modules/Environments

Page 20: [Celix] Scaling DevOps with Puppet and Perforce

20

Option C:

A single Git Repository for the Puppet Environment that uses Git

Submodules to include the Git Repositories for the Modules

firewall

Puppet Environment

ntp

stdlib

apache

Version the Environment Folder and all Modules

Versioning Puppet Modules/Environments

Page 21: [Celix] Scaling DevOps with Puppet and Perforce

21

main

forge

apache

stdlib

firewall

Managing Puppet Environments with Perforce Git Fusion

apache

stdlib

firewall

environment

Page 22: [Celix] Scaling DevOps with Puppet and Perforce

22

main

forge

apache

stdlib

firewall

Managing Puppet Environments with Perforce Git Fusion

environment

Puppet Environment

apache

stdlib

firewall

Page 23: [Celix] Scaling DevOps with Puppet and Perforce

23

feature_4

release_12.3

forge

feature_1

hotfix_1

release_13.1

feature_2 feature_3

Mainline Model for Puppet Modules

mainline

Page 24: [Celix] Scaling DevOps with Puppet and Perforce

24

• Modularity – Puppet Environment Repository is

assembled from multiple Module Repositories

• Easy Workflow - NO Git Submodules

• Central Change History in Perforce

• Fine grained Permissions

Perforce Git Fusion - Benefits

Page 25: [Celix] Scaling DevOps with Puppet and Perforce

25

Puppet Console

Puppet Module Forge

Build and Deploy Version Management Process Management

Puppet Agent Facter

NODE

Puppet Agent Facter

NODE

Puppet Agent Facter

NODE

Puppet Agent Facter

NODE

Puppet Agent Facter

NODE

Puppet Master

Modules/Environments

Puppet Architecture

Page 26: [Celix] Scaling DevOps with Puppet and Perforce

26

Catalog 1

2

3

4 Report

Collector Report

Report

Facts SSL secure

Encryprion

on all data

transport

Puppet

Master

Node

Puppet Data Flow

Page 27: [Celix] Scaling DevOps with Puppet and Perforce

27

Scaling DevOps

Agile Flow of Change for Puppet Modules

Page 28: [Celix] Scaling DevOps with Puppet and Perforce

28

• More Teams/Services adopt DevOps Practices

• Number of Environments and Modules grows

• Fine grained Security becomes more important

• Central Change history is required

• Processes are standardized

• Environments are standardized

• Puppetized Deployments are used across all Stages

What means Scaling DevOps?

Page 29: [Celix] Scaling DevOps with Puppet and Perforce

29

release_12.3

rails_webapp

hotfix_1

release_13.1

feature_1 feature_2

apache

zend_webapp

java_app

mainline

Agile Flow of Change for Puppet Modules

Page 30: [Celix] Scaling DevOps with Puppet and Perforce

30

rel_12.3

java_app

rel_13.1

zend_webapp apache

feature_2 feature_1

rails_webapp

main

apache_only

Agile Flow of Change for Puppet Modules

Page 31: [Celix] Scaling DevOps with Puppet and Perforce

31

apache

rails_webapp

zend_webapp

All trademarks and logos are property of their respective owners

main

rails

webapp rails

webapp zend

webapp zend

webapp

Perforce Streams Modularity

rails

webapp zend

webapp

Page 32: [Celix] Scaling DevOps with Puppet and Perforce

32

Development Quality Assurance Staging Production

Feature Stream Service Stream Mainline Stream Release Stream/Tag

Build Automation - The Puppet Environment Lifecycle

Page 33: [Celix] Scaling DevOps with Puppet and Perforce

33

Puppet Console

Puppet Module Forge

Build and Deploy Version Management Process Management

Puppet Agent Facter

NODE

Puppet Agent Facter

NODE

Puppet Agent Facter

NODE

Puppet Agent Facter

NODE

Puppet Agent Facter

NODE

Puppet Master

Modules/Environments

Summary

Page 34: [Celix] Scaling DevOps with Puppet and Perforce

34

Thank you.

[email protected]