slidenumbers: true
=======
- Automation Engineer, Chef
- Co-author of "Effective Devops"
- DevOpsDays SV Organizer
- Sparkly Devops Princess
- CoffeeOps Organizer
- Web Operations Engineer, Etsy
- Co-author of "Effective Devops"
- DevopsDays NYC Organizer
- Ladies Who Linux NYC Organizer
- Ship Show Podcast Co-host
- Jennifer Davis Twitter: @sigje Email: iennae@gmail.com
- Katherine Daniels Twitter: @beerops Email: sparklyyakshaver@gmail.com
^ J, K
- Constructive feedback
- What did you find helpful?
- What would you like to see more/less of?
- Was there anything you found unclear?
^ K
- Introduction to teams, devops principles
- 10:30-11am Morning Break
- Visualization of work, Git, Infrastructure automation
- 12:30-1:30pm Lunch
^ J
- Testing infrastucture automation and other changes
- 3-3:30pm Afternoon Break
- Measuring, monitoring, and wrap-up
^ J
Network Name: Conference_Private Access Code: velocity2015
- Safe space to share experiences, learn from each other
- Code of Conduct
- Learn effective workflows for using and testing source control and configuration management
^ K
- Meet your team!
- Identify your team's...
- Speaker
- Gatekeeper
- Notetaker
Time: 10 minutes
^ K: Because of time, 2 minutes per speaker, gatekeeper should also time speaker
^ J
- Technical cultural weave that shapes how we work, and why
^ J,K
- general popularly understood meaning particular to a socio-cultural grouping but which has not been formally defined or standardized.
^ K
^ J,K
2014 PuppetLabs State of DevOps Survey
^ J
2014 PuppetLabs State of DevOps Survey
^ J
- Collaboration
- Hiring
- Affinity
- Tools
- Scaling
^ K
- Individuals Working Together
^ K
- Choosing Individuals
^ K
- From Individuals to Teams
^ K
- Choosing and Using them
^ K
- Growing and Decreasing
^ K
^ J: Not enough time to cover all pillars. Not enough time to go into great depth which is why we are writing a book! We're going to focus on elements of collaboration and tools today. We'll be doing "Hiring and Tools" at Velocity NY.
- shared mutual understanding
- established boundaries
^ J,K: Book example (bad first, then good)
- Agency
- Adaptability: Role adherence
^ J
^ K: When people are conditioned through environment that they have no control, will not act to change condition, example
A life becomes meaningful when one sees himself or herself as an actor within the context of a story.
-- George Howard
^ K: Work is meaningful when people see themselves as active participants. Sharing story is critical part of building resilience.
- Skillful self disclosure
- What you share, how you share it
- Collective tasks vs personal agendas
^ J
- Common purpose
- Defined beliefs
- Empowered
^ J
- Large teams - roles may be highly segregated
- Small teams - one person may be responsible for many roles
^ K
- Collect stories
- Listen
- Circle back
^ K: this is how you transform a group into a team
Smarter Teams Build Better Value1
- Lots of Communication
- Contribute equally to team's discussions
- Theory of Mind
- Increased diversity
^ J
- Code Review
- Pairing
^ K
- Max 90 minutes in one setting
^ K
- Agile software development
- 2 people work together on 1 workstation
- Driver - writes code
- Observer - reviews each line
- Roles switch frequently
^ J
- Expert-expert
- Expert-novice
- Novice-novice
^ J
^ When experts pair, work gets done quickly, new innovation not always obtained, depending on skill overlap because not questioning accepted standards of doing things.
^ When expert and novice pair, can be very good or very bad. if expert isn't patient and does all the typing, novice learns helplessness and slow to get anything done. if expert is patient can involve growth for both as novice helps expert to question standards.
^ When novices pair, can work together to learn and achieve more than a novice working on their own. If no understanding in pair, and fire-fighting schedules can lead to poor practices implemented into production higher technical debt.
- What are motivations?
- What are current beliefs?
- What are current skills? Gaps in skills? Time: 15 minutes
^ J
- Team Name:
- Common Motivations?
- Skills? Gaps?
^ K
- Game about change.
- Rules change as you play.
- Goal changes frequently.
^ J
- Starts out with 1 Rule - Draw 1, Play 1
- Find this card (white backing)
- Place card in the middle of table
^ J
- Shuffle deck
- Deal 3 cards to each player
^ J
- First player is the person to left of Dealer.
- Start out following the Draw 1, Play 1 rule until overridden by new rules.
^ J
4 types of cards
- Goal - pink
- Keeper - green played in front of you
- Action - blue used once and discarded
- Rule - yellow
^ J
- Draw the number of cards currently required.
- Play the number of cards currently required.
- Discard down to hand limit (if any hand limit).
- Discard down to keeper limit (if any keeper limit).
^ J
- Winner is the first to meet the current Goal condition.
Time: 15 minutes
^ K
Change is inevitable.
^ K
- Build resilience
- Build collaboration (or competition)
- Roles change
^ J
- Frustration of constant changing goals
- Completed "work", lost value
- Visualization of goals, everyone in alignment
^ J
^ THIS SHOULD BE JUST BEFORE THE FIRST BREAK AT 10:30
- Bug/issue queue
- Kanban
^ K
- Start with what you do now
- Agree to incremental, evolutionary change
- Respect
- Everyone is a leader
^ K: Model what you're currently doing: how does work get done, what states do things get into, how do things get blocked ^ Everyone on the team is empowered to pull things, to suggest change, to create their stories
- Visualize
- Limit WIP
- Manage flow
- Make policies explicit
- Implement feedback loops
^ K
- Intent
- Alignment
- Coherence
^ K (tie back to Fluxx)
- Pull (don't push)
^ K
- Monitor/measure/report
- Incremental change
^ K
- Document processes
- Group signoff
^ K
- Collaboration
- Retrospectives
^ K (tie back to fluxx)
^ J
^ The company has decided to implement a "JoeNGo" web site that will allow for individuals to find a local coffeeshop and meet up friends who have available time on an ad-hoc basis.
^ Your company currently uses LAMP stack for other applications. Your team needs to decide based on experience whether to extend off of current standards or introduce new technology into your stack.
^ You need to plan, implement, and deploy infrastructure code that will allow rapid iteration on the site while also incorporating visual assests from designers, feedback from marketing and sales, while monitoring the costs of the solution.
Deming Cycle
- Plan: Identify and Analyze problem
- Do: Develop and Test potential solution
- Check: Measuring effectiveness
- Act: Implement solution
^ J
- (L)inux
- (A)pache
- (M)ySQL
- (P)HP, Perl, or Python
^ J
Time: 15 minutes
^ J
- Establish local development environment
- Version control
- Manual -> Automation -> Continuous
- Artifacts
- Infrastructure
- Sandbox
- Test and Build
- Monitoring
^ J
- Consistent set of tools across the team
- Ability to quickly onboard new engineers
^ K
- AWS instance node
- Chef DK
- Test Kitchen
- Ruby
- ChefSpec, ServerSpec
- Git
^ K
^ J
- Process of identifying, managing, monitoring, and auditing a product through its entire life including the processes, documentation, people, tools, software, and systems.
^ J
- Records changes to files or sets of files stored within the system
- Enable revisions
- Integrity checking
- Collaboration
^ J
- Secure
- Trusted
- Stable
- Accessible
- Versioned
^ K (artifactory, nexus, yum, package.io, rubbygems)
^ K
- Not automatically updated
- Manually pull upstream commits
^ K
$ git init
$ git add .
adds all files and directories to version control
^ K
$ git commit -m "message about commit" -a
^ K
All these changes are local! How do you collaborate?
^ K
$ git remote -v
^ K
$ git remote add NAME URL
^ K
$ git push REPONAME BRANCH
^ K
$ git branch -a
^ K
$ git checkout -b BRANCHNAME
^ K
$ git merge BRANCH
^ K
- import commits, from remote to local
git checkout master git log origin/master git merge origin/master
^ K
- feature branch
- gitflow
- forking
- centralized
^ K
- collaboration prior to integration
- discussion
- follow up commits
- selfie gifs1
^ K
git pull REMOTE
^ K
- ensure linear history by preventing unnecessary merge commits
^ K
- transfer commits from a local repo to a remote repo.
- counterpart to git fetch
^ K
Time: 15 minutes
^ K
- Aggregate of applications, configurations, access control, data, compute nodes, network, storage, processes, and people.
^ J
- Systems that reduce the burden on people to manage services and increase the quality, accuracy and precision of a service to the consumers of a service
^ J
- Chef
- Puppet
- Ansible
- Salt
- CFEngine
^ J
^ J, Baking Cookies
- Ingredients of infrastructure
- Basic building blocks
RESOURCETYPE "RESOURCE_NAME" do
PARAMETER PARAMETER_VALUE
endA package to be installed:
package "httpd" do
action :install
endA service that should be started:
service "httpd" do
supports :restart => :true
action [:enable, :start]
endA resource is a statement of policy that:
- Describes the desired state for an element
- Specifies a resource type---such as
package,template, orservice - Lists additional details (also known as parameters), as necessary
- Are grouped into recipes
- Collection of ordered resources
- Combination of ruby and Chef DSL
- Thematic
- Collection of recipes and other supporting files
- Abstraction describing function of system
- Name
- Description
- Run list (ordered list of recipes and roles)
- Ordered list of recipes and roles
- Specific to a node
- Machine (virtual, physical, cloud server, or other device) that is managed by Chef
- Abstraction models workflow
- Name
- Description
- Cookbook version pinning
- Community site with a number of cookbooks
- Read before using in your environment
- Chef development kit
- Includes a number of utilities and software to facilitate cookbook creation
- Free download off of the website
- Dependency management
- Included with Chef DK
- Included with Chef DK
- Sandbox automation
- Test harness
- Execute code on one or more platforms
- Driver plugins supporting various cloud and virtualization providers
- driver
- provisioner
- platforms
- suites
- virtualization or cloud provider
Example: vagrant, docker
- application to configure the node
Example: chef_zero
- target operating systems
Example: centos-6.5
- target configurations
Example:
name:default
run_list:
- recipe[apache::default]
attributes:
- kitchen init
- kitchen list
- kitchen create
- kitchen converge
- kitchen verify
- kitchen destroy
- kitchen test
- Images
- Registries
- Containers
Time: 20 minutes
^ THIS SHOULD BE RIGHT BEFORE LUNCH ^ J
- Test
- Small frequent releases
- Ensure code adheres to styles and conventions
- Weave expectations into development
- Encourages collaboration
- Documenting objectives and intent
- Measuring "done"
- foodcritic
- rubocop
- ServerSpec
- Ruby linter
- Ruby style guide
- Included with ChefDK
$ rubocop cookbooks/COOKBOOK1 cookbooks/COOKBOOK2 cookbooks/COOKBOOK4
Inspecting 8 files
CWCWCCCC
.means that the file contains no issuesCmeans a issue with conventionWmeans a warningEmeans an errorFmeans an fatal error
Any configuration in .rubocop.yml is disabled.
To disable string literals:
StringLiterals:
Enabled: false
- Chef linter
- Chef style guide
- Included with ChefDK
$ foodcritic cookbooks/setup
FC008: Generated cookbook metadata needs updating: ./metadata.rb:2
- Tests to verify servers functionality
- Resource types
- Package, service, user, and many others
- Integrates with Test Kitchen
- http://serverspec.org
describe "<subject>" do
it "<description>" do
expect(thing).to eq result
end
end
- Is the service running?
- Is the port accessible?
- Is the expected content being served?
describe 'apache' do
it "is installed" do
expect(package 'httpd').to be_installed
end
it "is running" do
expect(service 'httpd').to be_running
end
end
app::default
httpd service is running
Finished in 0.26429 seconds (files took 0.7166 seconds to load)
1 example, 0 failures
Time: 10 minutes
Time: 15 minutes
Time: 20 minutes
^ THIS WILL BE RIGHT BEFORE THE AFTERNOON BREAK
Test, Monitor, or Diagnostic2
- Where is it going to run?
- When is it going to run?
- How often will it run?
- Who is going to consume the result?
- What is the entity going to do with it?
^ J
^ K
- Overall site/app availability
- Individual service availability
- Uptime:
- Pingdom, Monitis, Uptrends, etc
- Vertical Line Technology:
- Availability after deploys/changes
- Nagios: Service-level monitoring and alerting
- Nagios-herald: Alert context
- OpsWeekly: Historical alert data
define command {
command_name check_mongodb_query
command_line $USER1$/nagios-plugin-mongodb/check_mongodb.py
-H $HOSTADDRESS$ -A $ARG1$ -P $ARG2$
-W $ARG3$ -C $ARG4$ -q $ARG5$
}
define service {
use generic-service
hostgroup_name Mongo Servers
service_description Mongo Connect Check
check_command check_mongodb!connect!27017!2!4
}
define servicedependency{
host_name WWW1
service_description Apache Web Server
dependent_host_name WWW1
dependent_service_description Main Web Site
execution_failure_criteria n
notification_failure_criteria w,u,c
}
- Service quality (SLAs)
- Visibility of quality
>>> import statsd
>>>
>>> timer = statsd.Timer('MyApplication')
>>>
>>> timer.start()
>>> # do something here
>>> timer.stop('SomeTimer')
>>> import statsd
>>>
>>> counter = statsd.Counter('MyApplication')
>>> # do something here
>>> counter += 1
>>> import statsd
>>>
>>> average = statsd.Average('MyApplication', connection)
>>> # do something here
>>> average.send('SomeName', 'somekey:%d'.format(value))
- Better for customers
- Better for employees (internal services)
- Fewer pages
- Deploys take less time
- Also better for customers
- More visibility into issues
Time: 20 minutes
- Recognizing your Devops Narrative
- Application Deployment Planning
- Infrastructure as code
- Introducing repeatable, testable change
- Measuring impact and value of change
^ Devops compact, Empathy, Learned Helplessness, Telling your story
^ Planning your application, Deming Cycle, don't just start solving things
^ Devops tools, including infrastructure as code
^ Testing
^ Monitoring, measuring impact and value of change
- Manual, Automation to Continuous "X"
- Be the storylistener and storyteller in your org
- Effective Devops available in Early Release
Footnotes
-
Engel, David et al. 'Reading The Mind In The Eyes Or Reading Between The Lines? Theory Of Mind Predicts Collective Intelligence Equally Well Online And Face-To-Face'. PLoS ONE 9.12 (2014): e115212. Web. 26 May 2015. ↩ ↩2
-
Lam, Yvonne. 'Sysadvent: Day 5 - How To Talk About Monitors, Tests, And Diagnostics'. Sysadvent.blogspot.com. N.p., 2014. Web. 26 May 2015. ↩



























