5. How I got Started
⢠Oracle *.*
⢠Enterprise Linux
⢠Needed a way to not waste every Monday and
every day I needed to refresh/clone
⢠Kill technical debt
⢠âClassic Enterprise..â
@byron_miller 5
6. Vocabulary
⢠Convergence â stabilize over time
⢠Idempotent â unchanged element when
operated on by itself
⢠Orchestration â Coordination & Management
of complex systems
⢠Puppet â The ecosystem
⢠Manifests & Modules â The code
@byron_miller 6
7. More Vocabulary
⢠ENC â External Node Classifier
⢠Mcollective â orchestration tool set
⢠Hiera â key value lookup system
⢠Node â Server/VM
⢠Facter â node facts
⢠Types & Providers â Built in resources you
declare in puppet manifests
@byron_miller 7
9. Begin by thinking
⢠Puppet has a learning curve but making it
work for your organization is up to how you
define âgetting things doneâ and your future
⢠The âvocabularyâ and âVerbiageâ of puppet is
well documented & simple with a little
practice
⢠Think about your work
⢠Think about your future
@byron_miller 9
11. Getting Started â Set Goals
⢠What is your goal(s)?
⢠How do you measure success or failure?
⢠What is your Intent?
Know the theory of your desired state
@byron_miller 11
12. How do you work?
⢠Is your organization highly constrained &
highly ordered?
⢠Do you strive for self-regulating systems?
⢠Is your goal compliance?
⢠Stability?
⢠Agility?
@byron_miller 12
13. Define Workflow
⢠Simple
â Easy to install & Maintain
⢠Safe
â Version Control - âGit workflowâ
⢠Secure
â SSH / SSL / Accountability
⢠Scalable
â Handle 1000s of nodes
@byron_miller 13
15. Long term..
⢠Simple â Donât add complexity
⢠Safe â Safe to fail experimentation
⢠Secure â Auditable
⢠Scalable â Point in time convergence.
@byron_miller 15
16. Practice
⢠Track your theories
⢠Test your theories
⢠Experiment
⢠Experiment again
⢠Never underestimate the value of POCâs.
@byron_miller 16
20. DRY â Donât repeat yourself
⢠Imposed Duplication â Apparent lack of
choice
⢠Inadvertent Duplication â Not realize that
theyâre duplicating information
⢠Impatient Duplication â lazy / duplicate
because it seems easier
⢠Interdeveloper Duplication â Multiple people
on teams / multiple teams.
21. Code
⢠Keep low level knowledge in code
⢠Reserve Comments for high level expectations
⢠Foster an environment where itâs easier to
find and reuse existing stuff than to write it
yourself.
22. Scope & Avoid Global data
⢠Every time you reference global data it ties
you to the other components that share data
⢠Use Scoping
23. Manage Complexity
Complexity is generally used to characterize
something with many parts where those parts
interact with each other in multiple ways.
24. Orthogonal - Safe to Fail
⢠Independent / lightly coupled systems
â Eliminates effects of unrelated things
â Design self contained things
⢠Increased productivity & contained risk
25. Prototype (experiment)
⢠Architecture
⢠New functionality in existing systems
⢠Structure or contents of external data
⢠Third party tools or components
⢠Performance issues
⢠User interface / experience / design
26. Experiments
⢠Worry less about correctness, completeness,
robustness and style.
⢠Focus on design / definition
⢠Is coupling minimized?
⢠Can you identify potential sources of
duplication?
28. Test
⢠Loosely coupled systems easier to test â
interactions between components are limited.
â Unit testing is easier
â Test in CI pipeline
⢠Beaker / rspec / puppet lint
29. Refactor
⢠Avoid code rot. Donât let bad code fester and
turn all your code into abandonware
⢠Code rot will keep you from staying current,
maintaining your skills and generally cause
people to shy away from platform for new
shiny thing..
34. Class Inheritance
⢠Use within a module to reduce repetition
(DRY)
⢠Inheriting from other modules decreases
modularity, but hard to avoid
â ENC confusion
35. Code Defensively
⢠Catch unexpected events before they break
things â gracefully bow out if you donât support
platform
â Default case fail on unsupported platforms
⢠Plan for Puppet Future parser
â Some changes / restrictions
â Expressions, Lambdas, Iterations & more
https://docs.puppetlabs.com/puppet/latest/refere
nce/experiments_future.html
36. Itâs code butâŚ
⢠Donât think of it as âobject orientedâ from a
programmers perspective
⢠Itâs a âDomain Specific Languageâ (DSL) used
to describe a desired state.
@byron_miller 36
37. Practice
⢠Vagrant / VM instances
â Build / test / deploy
â Pull modules from forge
⢠Read
⢠Test
⢠Deploy
⢠experiment
@byron_miller 37
41. Simple Domain
⢠Start with what you know
⢠Relieve pain points
⢠Remove constraints
⢠âCause â effectâ relationships â you can codify
this
@byron_miller 41
43. Simple -> Chaos
⢠When simple breaks
â All hell breaks loose.
@byron_miller 43
44. Infrastructure
⢠as code..
Busting out some Deming..
âAs a System of profound knowledgeâ
A. Appreciation for a system
B. Theory of Variation
C. Theory of Knowledge
D. Psychology
@byron_miller 44
45. Systems Approach
Taking a systems approach results in viewing the
organization in terms of many internal and
external interrelated connections and
interactions as opposed to discrete and
independent departments or processes
governed by various chains of command.
Appreciation for a system..
@byron_miller 45
46. Variation
Why did something go wrong? How can we
repeat success?
Common Cause â predictable variation within a
system
Special Cause â unique event outside the system
@byron_miller 46
49. Management Is..
⢠Prediction
⢠Theory
â What causes positive interactions?
â What removes conflict?
⢠Understanding & Conveying meaning of a
system
⢠People..
@byron_miller 49
51. The system
Intent..
⢠What causes behaviors outside the system?
âThe obligation of any component is to
contribute its best to the system but it will not
do that unless the system is managedâ
@byron_miller 51
53. Where we want to be
Future Backwards: Perspectives of people
within an organization give them a limited view
of the present, and such entrained patterns of
past perception can determine its future.
@byron_miller 53
54. Your future
Getting there..
⢠Flow
⢠Measure
⢠Retrospectives
⢠Involve Stakeholders
⢠Sense -> Categorize -> Respond
âBias against creativity is fueled by uncertaintyâ
-Deming
@byron_miller 54
55. Puppet Operations
⢠Develop your âSystemâ to allow
experimentation, upkeep, maintenance and
operational agility.
⢠Keep it Simple
⢠Grow & Learn
⢠Practice all the time
⢠Practice More
@byron_miller 55
56. Ops Pipeline
⢠Build Build Build
â Just like code rot, donât have server rot
CI
⢠Puppet Lint
⢠Beaker/Rspec/ServerSpec
⢠Rubocop
@byron_miller 56
57. Keep it simple
⢠Decouple!
â Use Roles & Profiles (the one âpatternâ Iâll always
recommend)
â Hiera is your friend, but donât go too nuts
â Keep your ENC simple - categorization
@byron_miller 57
58. Use the feedback loops
⢠Pay attention to pipeline
â Donât let things rot
â Seek out improvements
â Share lessons learned
â Get feedback
⢠Puppet Reports..
⢠Puppet Dashboard..
⢠Event Inspector (PE).. (and other tools)
@byron_miller 58
59. Donât stop Thinking
⢠Maintain a consistency of understanding and
effort
⢠Donât focus on local optimums
⢠Quality starts here
⢠Quality starts with intent
⢠No system whatever the effort put in will be
free from accident/incident/error
@byron_miller 59
60. Enable People
⢠Puppet enables me to codify to âmy futureâ
⢠Puppet enables me to know my past
@byron_miller 60
61. Practice
⢠Test Upgrades
⢠Test new forge modules
⢠âSafe to failâ experimentation
⢠Serverspec.. Beaker..
@byron_miller 61
62. Keep trying
⢠Look at logs
⢠puppet --debug âverbose
⢠Talk to community
⢠Use the dashboard
⢠puppet --help
@byron_miller 62
63. Community
⢠Google Groups
⢠Twitter
⢠âAskâ puppetlabs
⢠Online Documentation
⢠IRC
⢠User Groups!!
⢠Sh*t Gary Says - http://garylarizza.com/
@byron_miller 63
64. Questions?
âOrganizations which design systems⌠are constrained to
produce designs which are copies of the communication
structures of these organizations.â
- M. Conway
@byron_miller 64
Hinweis der Redaktion
Theory gives us the philosophical rails we need to have a successful implementation. It helps us think through what matters to the teams, the business and the operations of the systems that puppet is managing.
Puppet has a learning curve, but it is fairly simple
Is your goal to automate specific tasks, scale growth? Build out hundreds or thousands of servers? What are your success criteria's? How do you define your intent and how to establish that? I like to create a story in a wiki to describe the state of the system myself.
Organization type will help you know your boundaries and deliverables. If you have a highly ordered/constrained work environment you may focus more on controls in your pipeline, how you audit changes and restrict who has access to one. If you have a self-regulated system a Pull Request github style If no one has a firm grasp of puppet you may constrain your own system as you gain experience.
Workflow philosophy
Module Philosophy.. - everyone is a developer, everyone should adhere to style guide and everything should be testable and tested.
Start simple, but plan for long term goals â have them in back of your mind. Donât add complexity for sake of complexity. For some people as they grow scalability is less of an issue and long term your goals may be point in time convergence. Not every node needing to check in every x minutes, but orchestrated puppet runs satisfying business needs.
I would never under estimate the value of a proof of concept and experimenting with your theories in fact, Iâd wager many of us have gone awry or had regrets because our initial design is what became âproductionâ
Your entire success lies in making quality a requirement. If you have bad code, you will have a bad time. If no one can read it, understand it, embrace it, use it or it just doesnât work your entire ecosystem will reflect this. On the flipside I wouldnât look at the puppet DSC in the light of say a âpythonistaâ or ârubyistâ looking for the most elegant way to do something in least amount of code. Puppet DSC should be readable and simple
Decouple!
Worth repeating. Puppet manifests are code, treat it as such.
Kin-ev-in â cynafin â âmany placesâ
Common cause â can address with experimentation and puppet
Special Cause
What does it mean to be in operations? Managing what?
Helps give an overview of the hopes and fears of their organization and helps them understand which entrained patterns of past perception are influencing its future.
The ecology of âgetting work doneâ has more impact on delivering âyour futureâ than the tech/tools themselves. âASHENâ methodology
Weâre not striving for perfection, I choose to strive for getting the most work done with least resistance and most consistency.
Puppet enables me to operate in âComplex and Complicatedâ domains to seek out innovation & emergent properties of system