DevOps - Solution Pitch Deck

DevOps: CI/CD to Azure through
Codeship
Jessica Deen
Technical Evangelist - Microsoft
www.jessicadeen.com | @jldeen
[email protected]
Agenda
•
•
•
•
•
•
•
•
Review “DevOps,” what it is, and why it matters
Azure Breakdown
Codeship Breakdown
Quick overview of the code and how it works
Live demo
Deeper dive into the code
Live demo
Questions
What is DevOps?
“It’s a job title”
“It’s automation”
“It’s Development and
Operations collaboration”
“It means faster and
smaller releases”
PEOPLE
Collaborate more
Share common goals
Focus on improvement
BRINGING PEOPLE TOGETHER
The DevOps
conversation
PROCESS
Eliminate waste
Increase efficiency
Streamline feedback
DELIVERING VALUE FASTER
TOOLS
Enhance productivity
Enable collaboration
Facilitate experimentation
EXECUTING A DEVOPS STRATEGY
DevOps habits and practices
PRACTICES
Application Performance Management
PRACTICES
Infrastructure as Code
PRACTICES
Automated Testing
Continuous Deployment
Usage
Continuous Integration
Continuous Deployment
TEAM
AUTONOMY
& ENTERPRISE
ALIGNMENT
BACKLOG
refined with
LEARNING
Automated Recovery
Automated Testing
Testing in Production
Continuous Measurement
Stakeholder Feedback
FLOW OF
CUSTOMER
VALUE
Configuration Management
Code Reviews
Collection
Release Management
Release Management
PRACTICES
Telemetry Monitoring
EVIDENCE
gathered in
PRODUCTION
PRACTICES
PRACTICES
Testing in Production
Enterprise Agile
Usage Monitoring
Continuous Integration
User Telemetry
Continuous Deployment
Stakeholder feedback
Release Management
Feature flags
MANAGED
TECHNICAL
DEBT
PRODUCTION
FIRST MINDSET
INFRASTRUCTURE
is a FLEXIBLE
RESOURCE
PRACTICES
Application Performance Management
Infrastructure as Code
Continuous Delivery
Release Management
Configuration Management
Automated Recovery
https://puppetlabs.com/
End-to-end DevOps
1
Plan + track
Development
2
Develop + test
4 Monitor + learn
Production
3 Release
Plan + track
It starts with an idea - and a plan
how to turn this idea into reality…
Project starts
Manage work
1
Develop + test
Track progress
Plan
Develop + test
After the iteration starts,
developers turn great ideas
into features and functionality …
2
Write code
Unit testing
Version control
Build
Build verification
Release
Source code management
All your code is linked directly to the story, bug, or task driving the work.
Flexible version control
Collaborate on code
Any IDE, any code
Test management
Test planning and tracking
Developer testing
Manual and
exploratory testing
Continuous integration (CI) – a DevOps practice
Issues
cspkg
•
Delivery delays
•
Non-working/low-quality code
•
Incomplete solutions
•
Rework
Value
DEV
•
Frequent integration
•
Higher quality
•
Repeatability
Release
When all tests pass, the build is deployed
to testing environments for each
stage in the release process …
Cloud
load testing
Integration testing
environment
Staging
environment
Monitor + learn
3
Automated functional
testing environment
Pre-production
environment
Continuous delivery (CD) – a DevOps practice
Issues
•
Slow delivery cadence
•
Limited predictability when deploying
•
Complexity when deploying
Value
DEV
•
Consistency
•
Accelerated deployment
•
Repeatability
•
Human error reduction
Continuous delivery
Streamline and automate the workflow between development and IT ops and
deliver higher quality software more frequently with less risk.
Continuous integration
Release management
Continuous quality
Infrastructure as code (IAC) – a DevOps practice
Value
•
Optimize resources
•
Accelerate delivery
Measure
DEV
OPS
•
Deployment rate
•
MTTR
Monitor + learn
When all tests pass, the build is deployed to testing environments for each
stage in the release process
Plan the next iteration
Feedback
Monitor
4
Monitor + learn
Streamline and automate the workflow between development and IT ops and
deliver higher quality software more frequently with less risk.
Stakeholder feedback
management
Application telemetry
Performance and
load testing
CI / CD Process
Code repository
Build + deploy
Backlog
Monitor and improve
Automated testing
User testing
Why does this matter?
YOU
CONTINUOUS INTEGRATION
WEB APPS
CONTINUOUS DEPLOYMENT
INFRASTRUCTURE
AZURE BREAKDOWN
HOW DO WE CONNECT?
• AUTHENTICATION
NON-INTERACTION AUTHENTICATION METHOD
• SERVICE PRINCIPAL NAME
• SPN CREATION SCRIPT
EXAMPLE:
az login \
--service-principal \
-u $spn \
-p $password \
--tenant $tenant
CODESHIP
BREAKDOWN
CODESHIP.AES
JET (LOCAL TOOL)
SERVICES
STEPS
Demo
CODESHIP
DEFINE
SERVICES - CODESHIP-SERVICES.YML (EXAMPLE)
BREAKDOWN
acsdeploy:
image: azuresdk/azure-cli-python:latest
encrypted_env_file: azure.env.encrypted
environment:
- Resource=LFNW-CS
- Location=eastus
- Servicename=ACSJDDemo
- Orchestrator=Swarm
- Dnsprefix=lfnwdemo
- sshkey=/deploy/lfnw.pub
volumes:
- ./:/deploy
sshtunnel:
build:
image: sshtunnel
dockerfile_path: sshtunnel/Dockerfile
add_docker: true
encrypted_env_file: azure.env.encrypted
environment:
- Servicename=ACSJDDemo
- Resource=LFNW-CS
- Orchestrator=Swarm
- local_port=2375
- remote_port=2375
CODESHIP
BREAKDOWN
DEFINE STEPS | CODESHIP-STEPS.YML (EXAMPLE)
- name: Azure ACS Deploy
service: acsdeploy
command: bash /deploy/deployment/acs_deploy.sh
- type: serial
name: SSH Tunnel
service: sshtunnel
steps:
- command: docker run -d --name docker-nginx -p 80:80 nginx
- command: docker ps -a
AZURE ACS
1.
ACS Deployment Methods
BREAKDOWN
1. Via Portal (Manual)
2. Azure CLI 2.0 (Manual)
3. Deployment Bash script using AZ CLI 2.0 (DevOps IAC)
2. SSH Tunnel to Docker Swarm Cluster
ssh -fNL 2375:localhost:2375 -p 2200
[USERNAME]@[DNSPREFIX]mgmt.[REGION].cloudapp.azure.com
Export DOCKER_HOST=:2375
End result: Pass Docker commands natively to Swarm cluster through newly created SSH
tunnel
YOU
CONTINUOUS INTEGRATION
WEB APPS
CONTINUOUS DEPLOYMENT
INFRASTRUCTURE
Demo
The shift to DevOps
OLD WORLD
Focus on planning
Compete, not collaborate
Static hierarchies
Individual productivity
Efficiency of process
Assumptions, not data
NEW WORLD
Focus on delivering
Collaborate to win
Fluent and flexible teams
Collective value creation
Effectiveness of outcomes
Experiment, learn, and respond
RECAP
HOW DO WE CONNECT?
• AUTHENTICATION
NON-INTERACTION AUTHENTICATION METHOD
• SERVICE PRINCIPAL NAME USING THE SPN CREATION SCRIPT
CODE IS SCALABLE!
IT’S JUST IAC – BASH SCRIPTS. THIS CAN SCALE WITH VIRTUALLY ANY CI/CD TOOL!
QUESTIONS?
Thank you!
www.jessicadeen.com | @jldeen
github.com/jldeen/
[email protected]
Channel 9 - https://channel9.msdn.com/Niners/jldeen