SlideShare uma empresa Scribd logo
1 de 42
#JenkinsWorld
Pipelining DevOps with Jenkins and AWS
Jimmy Ray
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
Me
• DevOps/Cloud Architect at Capital One
• Early-adopter and fast-follower of Cloud, DevOps,
and Java technologies
• “Serial Speaker”
• Jenkins Contributor: wrote Consul-KV-Builder Plugin
– https://wiki.jenkins-ci.org/display/JENKINS/Consul-
KV-Builder+Plugin
• Blog: http://www.techsand.com
• LinkedIn:
http://www.linkedin.com/in/iamjimmyray
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
Disclaimer – “The Buck Stops Here!”
• The ideas presented, and maybe even espoused, today are my own thoughts,
and do not reflect or represent those of my employer, customers, or
colleagues.
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
Agenda
• Today’s Architecture
– EC2 (Roles, Connections, etc.)
– Today’s Jenkins
– Today’s Pipeline
• AWS CodeCommit
• AWS CodeDeploy
• AWS Pipeline
• Best Practices
• Q and (maybe) A
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
Architecture
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
Architecture
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
SSH Agent Forwarding with Bastion Host
• Access Bastion host (with EIP) in public subnet using PEM key file and SSH.
– Will access others server via the Bastion host.
• Use SSH forwarding so that PEM file does not need to be stored on Bastion host
• Good solution for keeping hosts in private subnets without Internet Gateway
(IGW)
– Use route to NAT Gateway in public subnets
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
EC2 Roles for Your Jenkins Instances
• EC2 instances can be assigned IAM roles
– Must be assigned when EC2 is launched.
• These roles can then be used by processes on the EC2, including Jenkins
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
Using EC2 Instance Metadata
• Data about your EC2 instance that you can use from within your EC2 instance.
• http://169.254.169.254/latest/meta-data/iam/security-
credentials/JenkinsWorld2016JenkinsMaster
• Warning: You must control access to jobs that use AWS CLI, and control what
the role can do inside AWS.
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
Jenkins Tools
• Java 8
• NGINX
• Git
• AWS CLI
• Maven 3.3.9
• jq (https://stedolan.github.io/jq/)
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
Choose Your Jenkins Distro Wisely
• I like to use the Jenkins Long-Term Support release
– https://wiki.jenkins-ci.org/display/JENKINS/LTS+Release+Line
sudo wget -O /etc/yum.repos.d/jenkins.repo http://pkg.jenkins-ci.org/redhat-
stable/jenkins.repo
sudo rpm --import https://jenkins-ci.org/redhat/jenkins-ci.org.key
sudo yum install jenkins
sudo service jenkins start/stop/restart
sudo chkconfig jenkins on
curl localhost:8080
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
Choose Your Jenkins Distro Wisely (continued)
• I like the LTS versions, but I wanted/needed the latest features
– Alternatively, I could have upgraded the individual plugins for the new functionality
sudo wget -O /etc/yum.repos.d/jenkins.repo http://pkg.jenkins-
ci.org/redhat/jenkins.repo
sudo rpm --import https://jenkins-ci.org/redhat/jenkins-ci.org.key
sudo yum install jenkins
sudo service jenkins start/stop/restart
sudo chkconfig jenkins on
curl localhost:8080
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
New Shell Step Syntax
• Advanced configuration added
– Now sh step can return the standard output to variable assignment
– No longer need “sentinel” files
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
New Stage Syntax
• New syntax for stage definition:
– “Using the ‘stage’ step without a block argument is deprecated”
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
Today’s Jenkins Pipeline
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
Pipeline Utilities
• Use pipeline-utility-steps plugin
– https://wiki.jenkins-ci.org/display/JENKINS/Pipeline+Utility+Steps+Plugin
– https://jenkins.io/doc/pipeline/steps/pipeline-utility-steps/
• Setup tooling (Maven, Sonar, etc.) and reference this tooling in CPS
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
Pipeline Calling AWS CLI
• Watch your environment variables
– If used, put exports in the same shell call as AWS CLI call (context)
• Use the CloudBees Enterprise Jenkins AWS CLI Plugin
– Or, create IAM user and use access key and secret keys, with withEnv construct
– Or, use –-profile switch in AWS CLI call
– Or, use EC2 roles and credentials from EC2 metadata – DANGEROUS!!
– Or, set Jenkins AWS system-level configuration
– Or, used combination of CloudBees AWS Credentials and Credential Binding
Plugins
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
CloudBees AWS Credentials Plugin
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
CloudBees AWS CLI Plugin
• https://go.cloudbees.com/docs/cloudbees-documentation/cje-user-
guide/chapter-aws-cli.html
• Uses pipeline build wrapper to wrap AWS CLI calls in environment with proper
credentials.
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
CloudBees AWS CLI Plugin
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
Credentials Binding Plugin
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
Jenkins Master System-Level AWS Configuration
© 2016 CloudBees, Inc. All Rights Reserved
cd /var/lib/jenkins
sudo -u jenkins aws configure
#JenkinsWorld
AWS CLI - Create Test ENV Stage
• Create EC2 instance from known AMI, Security group, Subnet, Key Pair, Role
– Write JSON results to file
– Slurp file to get InstanceId, PrivateIpAddress
• Wait for instance to be “running”
– Need InstanceId to call “wait”
• Tag instance
– Need InstanceId
• Wait for instance to be reachable
– Then configure instance using ssh and PrivateIpAddress
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
AWS CLI - Create Test ENV Stage (continued)
• Install tools (Java, Tomcat, etc.)
• Install AWS CodeDeploy agent
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
jq
• Used in pipeline scripts to parse JSON using JMESPath
• Use JMESPath (JSON Matching Expression path) Terminal (jpterm) to build paths
– https://github.com/jmespath/jmespath.terminal
sudo su –
cd /usr/bin
wget http://stedolan.github.io/jq/download/linux64/jq
chmod +x ./jq
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
AWS CodeCommit
• Git repos in AWS
• Requires credential helper in .gitconfig
© 2016 CloudBees, Inc. All Rights Reserved
git config --global credential.helper '!aws --profile JenkinsWorld2016 codecommit
credential-helper $@’
git config --global credential.UseHttpPath true
#JenkinsWorld
AWS CodeCommit – AWS Temp Passwords
• If you are using OSX with CodeCommit you need to be aware of the issue
caused by AWS and your OSX Keychain utility
– AWS uses a temporary that will cause a 403 error if your OSX Keychain is not
configured properly
– http://docs.aws.amazon.com/codecommit/latest/userguide/setting-up-https-
unixes.html#setting-up-https-unixes-credential-helper
– Temp Fix: security delete-internet-password -l git-
codecommit.us-east-1.amazonaws.com
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
AWS CodeCommit Repos
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
AWS CodeDeploy
• …is a set of ALM services
• CodeDeploy is used to setup deployment resource targets, groups, and
deployment configurations
• Deploys to EC2 or ASG
– Allows for rollback via redeploy
• CodeDeploy Agent must be running on targets to receive deployments
– Uses appspec.yml to customize deployment when the deployment package is
delivered to the instance.
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
CodeDeploy Packaging
• Package artifacts to deploy via the CodeDeploy
– This is a ZIP file with the artifacts as well as the YAML (*.yml) file needed for
CodeDeploy automation
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
AWS CodePipeline
• Continuous Delivery Service
• Uses CodeDeploy to target resources
• Uses the concept of:
– providers
o Source, Deployment, Build, etc.
– Workers
– Actions
• Can use S3 (GitHub, CodeCommit) as pipeline source
– S3 bucket versioning is required
– Lifecycle Management recommended
• Can use Jenkins for build integration
• AWS CLI call to create CodePipeline
– Requires JSON config file
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
CodeDeploy and CodePipeline Role Assumptions
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
Timestamped Logs
• timestamps { //code block }
• Adds timestamped log entries
• Adds additional UI control when reviewing logs.
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
Best Practices and Possible Ideas
• Jenkins SCM Sync Configuration Plugin
• Bastion Hosts with SSH Forwarding
– or centralized security (example: Centrify)
• Groovy Sandbox and Script Approval
– Look out for serialization issues
– @NonCPS
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
Possible Next Steps…
• Move from Bastion host access to Centrify or similar tools.
– Reduce compromised credentials, stop using key-pairs
• Externalize scripts to shared libraries and Jenkinsfile
– Keep your code DRY (Don’t Repeat Yourself)
• Capture shell outputs to files to reduce noise in logs
• Replace shell-script configurations with CloudFormation or Terraform
• Add Chef or Ansible
• Move from EC2 to ECS (if/when CodeDeploy works with ECS)
• Move from master to Jenkins Agent node
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
Final Thoughts…
• There is a lot of room for improvement to the integration between Jenkins
Pipeline and AWS
– Plugins to be written and/or modified to be used with AWS resources
• Jenkins Pipeline is the “DevOps Equalizer”
– Instead of having to memorize the look and feel of many different plugins, CPS
syntax and lexicon is required.
– Programmers who have had a strong desire to use Jenkins are now re-empowered
• I would really like to be able to disable sandbox=true for
CpsScmFlowDefinition jobs.
• I would really like to be able control the size of the CodeMirror script editor in
the pipeline-job configuration screen
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld #JenkinsWorld
© 2016 CloudBees, Inc. All Rights Reserved
Questions?
#JenkinsWorld
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
Parking Lot (If We Have Time)
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
Pipeline Shared Libraries
• https://github.com/jenkinsci/workflow-cps-global-lib-
plugin/blob/master/README.md
• Helps you keep your pipeline code DRY
• Can use any GitRepo, even CodeCommit
– https://github.com/cloudbees/jenkins-scripts/blob/master/pipeline-global-lib-
init.groovy
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
Pipelines That Have Lost Their Way
• Occasionally, pipelines stop responding
– They may even show that they were “aborted”
– They are still ”spinning”
• In the Global Security, disable “Prevent Cross Site Request Forgery exploits”
• Then delete the job
– $JENKINS_URL/job/${JOB_NAME}/${BUILD_NUMBER}/doDelete
o Hit the “Try Posting” button if it appears
o May need to disable “Prevent Cross Site Request Forgery exploits” in Global Security.
• You may need to restart Jenkins: $JENKINS_URL/restart
• Easier to handle since OSS version 2.21
© 2016 CloudBees, Inc. All Rights Reserved
#JenkinsWorld
Pipelines That Have Lost Their Way (continued)
© 2016 CloudBees, Inc. All Rights Reserved

Mais conteúdo relacionado

Mais procurados

AWS CodeDeploy
AWS CodeDeployAWS CodeDeploy
AWS CodeDeploy
TO THE NEW | Technology
 

Mais procurados (20)

Code Deploy
Code Deploy Code Deploy
Code Deploy
 
Continuous Integration and Deployment Best Practices on AWS (ARC307) | AWS re...
Continuous Integration and Deployment Best Practices on AWS (ARC307) | AWS re...Continuous Integration and Deployment Best Practices on AWS (ARC307) | AWS re...
Continuous Integration and Deployment Best Practices on AWS (ARC307) | AWS re...
 
Continuous delivery and deployment on AWS
Continuous delivery and deployment on AWSContinuous delivery and deployment on AWS
Continuous delivery and deployment on AWS
 
Continuous Delivery to Amazon ECS
Continuous Delivery to Amazon ECSContinuous Delivery to Amazon ECS
Continuous Delivery to Amazon ECS
 
(DVO306) AWS CodeDeploy: Automating Your Software Deployments
(DVO306) AWS CodeDeploy: Automating Your Software Deployments(DVO306) AWS CodeDeploy: Automating Your Software Deployments
(DVO306) AWS CodeDeploy: Automating Your Software Deployments
 
Continuous Delivery using AWS CodePipeline, AWS Lambda & AWS ElasticBeanstalk
Continuous Delivery using AWS CodePipeline, AWS Lambda & AWS ElasticBeanstalkContinuous Delivery using AWS CodePipeline, AWS Lambda & AWS ElasticBeanstalk
Continuous Delivery using AWS CodePipeline, AWS Lambda & AWS ElasticBeanstalk
 
CI/CD on AWS Deploy Everything All the Time
CI/CD on AWS Deploy Everything All the TimeCI/CD on AWS Deploy Everything All the Time
CI/CD on AWS Deploy Everything All the Time
 
Devops with Amazon Web Services (January 2017)
Devops with Amazon Web Services (January 2017)Devops with Amazon Web Services (January 2017)
Devops with Amazon Web Services (January 2017)
 
DevOps at Amazon: A Look at Our Tools and Processes by Matthew Trescot, Manag...
DevOps at Amazon: A Look at Our Tools and Processes by Matthew Trescot, Manag...DevOps at Amazon: A Look at Our Tools and Processes by Matthew Trescot, Manag...
DevOps at Amazon: A Look at Our Tools and Processes by Matthew Trescot, Manag...
 
Azure Kubernetes Service - benefits and challenges
Azure Kubernetes Service - benefits and challengesAzure Kubernetes Service - benefits and challenges
Azure Kubernetes Service - benefits and challenges
 
AWS DevOps Event - AWS Services enabling DevOps - Continuous Integration & Au...
AWS DevOps Event - AWS Services enabling DevOps - Continuous Integration & Au...AWS DevOps Event - AWS Services enabling DevOps - Continuous Integration & Au...
AWS DevOps Event - AWS Services enabling DevOps - Continuous Integration & Au...
 
AWS CodeDeploy
AWS CodeDeployAWS CodeDeploy
AWS CodeDeploy
 
Day 3 - DevOps Culture - Continuous Integration & Continuous Deployment on th...
Day 3 - DevOps Culture - Continuous Integration & Continuous Deployment on th...Day 3 - DevOps Culture - Continuous Integration & Continuous Deployment on th...
Day 3 - DevOps Culture - Continuous Integration & Continuous Deployment on th...
 
DevOps at Amazon: A Look at Our Tools and Processes
DevOps at Amazon: A Look at Our Tools and ProcessesDevOps at Amazon: A Look at Our Tools and Processes
DevOps at Amazon: A Look at Our Tools and Processes
 
AWS CodeCommit, CodeDeploy & CodePipeline
AWS CodeCommit, CodeDeploy & CodePipelineAWS CodeCommit, CodeDeploy & CodePipeline
AWS CodeCommit, CodeDeploy & CodePipeline
 
DevOps, Continuous Integration and Deployment on AWS: Putting Money Back into...
DevOps, Continuous Integration and Deployment on AWS: Putting Money Back into...DevOps, Continuous Integration and Deployment on AWS: Putting Money Back into...
DevOps, Continuous Integration and Deployment on AWS: Putting Money Back into...
 
AWS OpsWorks for Chef Automate
AWS OpsWorks for Chef AutomateAWS OpsWorks for Chef Automate
AWS OpsWorks for Chef Automate
 
AWS CodeDeploy
AWS CodeDeployAWS CodeDeploy
AWS CodeDeploy
 
Building A CICD Pipeline for Deploying to Containers
Building A CICD Pipeline for Deploying to ContainersBuilding A CICD Pipeline for Deploying to Containers
Building A CICD Pipeline for Deploying to Containers
 
Installing WordPress on AWS
Installing WordPress on AWSInstalling WordPress on AWS
Installing WordPress on AWS
 

Destaque

Destaque (20)

DevOps with Amazon Web Services
DevOps with Amazon Web ServicesDevOps with Amazon Web Services
DevOps with Amazon Web Services
 
Introduction to DevSecOps
Introduction to DevSecOpsIntroduction to DevSecOps
Introduction to DevSecOps
 
Introduction to DevSecOps on AWS
Introduction to DevSecOps on AWSIntroduction to DevSecOps on AWS
Introduction to DevSecOps on AWS
 
DevOps in Amazon.com
DevOps in Amazon.com DevOps in Amazon.com
DevOps in Amazon.com
 
AWS re:Invent 2016: Building the Future of DevOps with Amazon Web Services (D...
AWS re:Invent 2016: Building the Future of DevOps with Amazon Web Services (D...AWS re:Invent 2016: Building the Future of DevOps with Amazon Web Services (D...
AWS re:Invent 2016: Building the Future of DevOps with Amazon Web Services (D...
 
AWS Summit Paris 2017 : DevOps in a container world
AWS Summit Paris 2017 : DevOps in a container worldAWS Summit Paris 2017 : DevOps in a container world
AWS Summit Paris 2017 : DevOps in a container world
 
DevOps on AWS: Accelerating Software Delivery with AWS Developer Tools | AWS ...
DevOps on AWS: Accelerating Software Delivery with AWS Developer Tools | AWS ...DevOps on AWS: Accelerating Software Delivery with AWS Developer Tools | AWS ...
DevOps on AWS: Accelerating Software Delivery with AWS Developer Tools | AWS ...
 
DevOps on AWS: Deep Dive on Continuous Delivery and the AWS Developer Tools
DevOps on AWS: Deep Dive on Continuous Delivery and the AWS Developer ToolsDevOps on AWS: Deep Dive on Continuous Delivery and the AWS Developer Tools
DevOps on AWS: Deep Dive on Continuous Delivery and the AWS Developer Tools
 
Cloudsolutionday 2016: DevOps workflow with Docker on AWS
Cloudsolutionday 2016: DevOps workflow with Docker on AWSCloudsolutionday 2016: DevOps workflow with Docker on AWS
Cloudsolutionday 2016: DevOps workflow with Docker on AWS
 
AWS re:Invent 2016: DevOps on AWS: Advanced Continuous Delivery Techniques (D...
AWS re:Invent 2016: DevOps on AWS: Advanced Continuous Delivery Techniques (D...AWS re:Invent 2016: DevOps on AWS: Advanced Continuous Delivery Techniques (D...
AWS re:Invent 2016: DevOps on AWS: Advanced Continuous Delivery Techniques (D...
 
Building a DevOps Culture in Public Sector | AWS Public Sector Summit 2017
Building a DevOps Culture in Public Sector | AWS Public Sector Summit 2017Building a DevOps Culture in Public Sector | AWS Public Sector Summit 2017
Building a DevOps Culture in Public Sector | AWS Public Sector Summit 2017
 
DevOps Tech Talk: Getting out of Operations Hell | AWS Public Sector Summit 2016
DevOps Tech Talk: Getting out of Operations Hell | AWS Public Sector Summit 2016DevOps Tech Talk: Getting out of Operations Hell | AWS Public Sector Summit 2016
DevOps Tech Talk: Getting out of Operations Hell | AWS Public Sector Summit 2016
 
AWS re:Invent 2016: Taking DevOps to the AWS Edge (CTD302)
AWS re:Invent 2016: Taking DevOps to the AWS Edge (CTD302)AWS re:Invent 2016: Taking DevOps to the AWS Edge (CTD302)
AWS re:Invent 2016: Taking DevOps to the AWS Edge (CTD302)
 
AWS re:Invent 2016: Automated DevOps and Continuous Delivery (DEV211)
AWS re:Invent 2016: Automated DevOps and Continuous Delivery (DEV211)AWS re:Invent 2016: Automated DevOps and Continuous Delivery (DEV211)
AWS re:Invent 2016: Automated DevOps and Continuous Delivery (DEV211)
 
Getting Started With Continuous Delivery on AWS - AWS April 2016 Webinar Series
Getting Started With Continuous Delivery on AWS - AWS April 2016 Webinar SeriesGetting Started With Continuous Delivery on AWS - AWS April 2016 Webinar Series
Getting Started With Continuous Delivery on AWS - AWS April 2016 Webinar Series
 
AWS re:Invent 2016: How I learned to embrace DevOps and Configure Infrastruct...
AWS re:Invent 2016: How I learned to embrace DevOps and Configure Infrastruct...AWS re:Invent 2016: How I learned to embrace DevOps and Configure Infrastruct...
AWS re:Invent 2016: How I learned to embrace DevOps and Configure Infrastruct...
 
AWS re:Invent 2016: DevOps on AWS: Accelerating Software Delivery with the AW...
AWS re:Invent 2016: DevOps on AWS: Accelerating Software Delivery with the AW...AWS re:Invent 2016: DevOps on AWS: Accelerating Software Delivery with the AW...
AWS re:Invent 2016: DevOps on AWS: Accelerating Software Delivery with the AW...
 
DevOps as a Pathway to AWS | AWS Public Sector Summit 2016
DevOps as a Pathway to AWS | AWS Public Sector Summit 2016DevOps as a Pathway to AWS | AWS Public Sector Summit 2016
DevOps as a Pathway to AWS | AWS Public Sector Summit 2016
 
DevOps on AWS: Deep Dive on Continuous Delivery and the AWS Developer Tools
DevOps on AWS: Deep Dive on Continuous Delivery and the AWS Developer ToolsDevOps on AWS: Deep Dive on Continuous Delivery and the AWS Developer Tools
DevOps on AWS: Deep Dive on Continuous Delivery and the AWS Developer Tools
 
Delivering DevOps on AWS: Accelerating Software Delivery with AWS Developer T...
Delivering DevOps on AWS: Accelerating Software Delivery with AWS Developer T...Delivering DevOps on AWS: Accelerating Software Delivery with AWS Developer T...
Delivering DevOps on AWS: Accelerating Software Delivery with AWS Developer T...
 

Semelhante a Pipelining DevOps with Jenkins and AWS

Semelhante a Pipelining DevOps with Jenkins and AWS (20)

Dev Ops
Dev OpsDev Ops
Dev Ops
 
Continuous Deployment with Amazon Web Services
Continuous Deployment with Amazon Web ServicesContinuous Deployment with Amazon Web Services
Continuous Deployment with Amazon Web Services
 
(DVO305) Turbocharge YContinuous Deployment Pipeline with Containers
(DVO305) Turbocharge YContinuous Deployment Pipeline with Containers(DVO305) Turbocharge YContinuous Deployment Pipeline with Containers
(DVO305) Turbocharge YContinuous Deployment Pipeline with Containers
 
Continuous Delivery to Amazon ECS - AWS August Webinar Series
Continuous Delivery to Amazon ECS - AWS August Webinar SeriesContinuous Delivery to Amazon ECS - AWS August Webinar Series
Continuous Delivery to Amazon ECS - AWS August Webinar Series
 
Managing Your Cloud Assets
Managing Your Cloud AssetsManaging Your Cloud Assets
Managing Your Cloud Assets
 
Aws container webinar day 2
Aws container webinar day 2Aws container webinar day 2
Aws container webinar day 2
 
HOW TO DRONE.IO IN CI/CD WORLD
HOW TO DRONE.IO IN CI/CD WORLDHOW TO DRONE.IO IN CI/CD WORLD
HOW TO DRONE.IO IN CI/CD WORLD
 
AWS re:Invent 2016: Development Workflow with Docker and Amazon ECS (CON302)
AWS re:Invent 2016: Development Workflow with Docker and Amazon ECS (CON302)AWS re:Invent 2016: Development Workflow with Docker and Amazon ECS (CON302)
AWS re:Invent 2016: Development Workflow with Docker and Amazon ECS (CON302)
 
Infrastructure Is Code with the AWS Cloud Development Kit (DEV372) - AWS re:I...
Infrastructure Is Code with the AWS Cloud Development Kit (DEV372) - AWS re:I...Infrastructure Is Code with the AWS Cloud Development Kit (DEV372) - AWS re:I...
Infrastructure Is Code with the AWS Cloud Development Kit (DEV372) - AWS re:I...
 
Integrating security testing into your container build pipeline - SDD308 - AW...
Integrating security testing into your container build pipeline - SDD308 - AW...Integrating security testing into your container build pipeline - SDD308 - AW...
Integrating security testing into your container build pipeline - SDD308 - AW...
 
Jenkins as a Service - Code all the way down
Jenkins as a Service - Code all the way downJenkins as a Service - Code all the way down
Jenkins as a Service - Code all the way down
 
Developer Experience at the Guardian, Equal Experts Sept 2021
Developer Experience at the Guardian, Equal Experts Sept 2021Developer Experience at the Guardian, Equal Experts Sept 2021
Developer Experience at the Guardian, Equal Experts Sept 2021
 
GPSTEC304_Shipping With PorpoiseA K8s Story
GPSTEC304_Shipping With PorpoiseA K8s StoryGPSTEC304_Shipping With PorpoiseA K8s Story
GPSTEC304_Shipping With PorpoiseA K8s Story
 
Continuous Delivery to Amazon EC2 Container Service
Continuous Delivery to Amazon EC2 Container ServiceContinuous Delivery to Amazon EC2 Container Service
Continuous Delivery to Amazon EC2 Container Service
 
A 60-minute tour of AWS Compute (November 2016)
A 60-minute tour of AWS Compute (November 2016)A 60-minute tour of AWS Compute (November 2016)
A 60-minute tour of AWS Compute (November 2016)
 
04_Azure Kubernetes Service: Basic Practices for Developers_GAB2019
04_Azure Kubernetes Service: Basic Practices for Developers_GAB201904_Azure Kubernetes Service: Basic Practices for Developers_GAB2019
04_Azure Kubernetes Service: Basic Practices for Developers_GAB2019
 
AWS re:Invent 2016: Deploying and Managing .NET Pipelines and Microsoft Workl...
AWS re:Invent 2016: Deploying and Managing .NET Pipelines and Microsoft Workl...AWS re:Invent 2016: Deploying and Managing .NET Pipelines and Microsoft Workl...
AWS re:Invent 2016: Deploying and Managing .NET Pipelines and Microsoft Workl...
 
A tale of two pizzas: Developer tools at AWS
A tale of two pizzas: Developer tools at AWSA tale of two pizzas: Developer tools at AWS
A tale of two pizzas: Developer tools at AWS
 
Automating Security in your IaC Pipeline
Automating Security in your IaC PipelineAutomating Security in your IaC Pipeline
Automating Security in your IaC Pipeline
 
Sebastien goasguen cloud stack and docker
Sebastien goasguen   cloud stack and dockerSebastien goasguen   cloud stack and docker
Sebastien goasguen cloud stack and docker
 

Último

Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
WSO2
 

Último (20)

Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
 
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Exploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusExploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with Milvus
 
Introduction to Multilingual Retrieval Augmented Generation (RAG)
Introduction to Multilingual Retrieval Augmented Generation (RAG)Introduction to Multilingual Retrieval Augmented Generation (RAG)
Introduction to Multilingual Retrieval Augmented Generation (RAG)
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
 
Six Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal OntologySix Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal Ontology
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 

Pipelining DevOps with Jenkins and AWS

  • 1. #JenkinsWorld Pipelining DevOps with Jenkins and AWS Jimmy Ray © 2016 CloudBees, Inc. All Rights Reserved
  • 2. #JenkinsWorld Me • DevOps/Cloud Architect at Capital One • Early-adopter and fast-follower of Cloud, DevOps, and Java technologies • “Serial Speaker” • Jenkins Contributor: wrote Consul-KV-Builder Plugin – https://wiki.jenkins-ci.org/display/JENKINS/Consul- KV-Builder+Plugin • Blog: http://www.techsand.com • LinkedIn: http://www.linkedin.com/in/iamjimmyray © 2016 CloudBees, Inc. All Rights Reserved
  • 3. #JenkinsWorld Disclaimer – “The Buck Stops Here!” • The ideas presented, and maybe even espoused, today are my own thoughts, and do not reflect or represent those of my employer, customers, or colleagues. © 2016 CloudBees, Inc. All Rights Reserved
  • 4. #JenkinsWorld Agenda • Today’s Architecture – EC2 (Roles, Connections, etc.) – Today’s Jenkins – Today’s Pipeline • AWS CodeCommit • AWS CodeDeploy • AWS Pipeline • Best Practices • Q and (maybe) A © 2016 CloudBees, Inc. All Rights Reserved
  • 7. #JenkinsWorld SSH Agent Forwarding with Bastion Host • Access Bastion host (with EIP) in public subnet using PEM key file and SSH. – Will access others server via the Bastion host. • Use SSH forwarding so that PEM file does not need to be stored on Bastion host • Good solution for keeping hosts in private subnets without Internet Gateway (IGW) – Use route to NAT Gateway in public subnets © 2016 CloudBees, Inc. All Rights Reserved
  • 8. #JenkinsWorld EC2 Roles for Your Jenkins Instances • EC2 instances can be assigned IAM roles – Must be assigned when EC2 is launched. • These roles can then be used by processes on the EC2, including Jenkins © 2016 CloudBees, Inc. All Rights Reserved
  • 9. #JenkinsWorld Using EC2 Instance Metadata • Data about your EC2 instance that you can use from within your EC2 instance. • http://169.254.169.254/latest/meta-data/iam/security- credentials/JenkinsWorld2016JenkinsMaster • Warning: You must control access to jobs that use AWS CLI, and control what the role can do inside AWS. © 2016 CloudBees, Inc. All Rights Reserved
  • 10. #JenkinsWorld Jenkins Tools • Java 8 • NGINX • Git • AWS CLI • Maven 3.3.9 • jq (https://stedolan.github.io/jq/) © 2016 CloudBees, Inc. All Rights Reserved
  • 11. #JenkinsWorld Choose Your Jenkins Distro Wisely • I like to use the Jenkins Long-Term Support release – https://wiki.jenkins-ci.org/display/JENKINS/LTS+Release+Line sudo wget -O /etc/yum.repos.d/jenkins.repo http://pkg.jenkins-ci.org/redhat- stable/jenkins.repo sudo rpm --import https://jenkins-ci.org/redhat/jenkins-ci.org.key sudo yum install jenkins sudo service jenkins start/stop/restart sudo chkconfig jenkins on curl localhost:8080 © 2016 CloudBees, Inc. All Rights Reserved
  • 12. #JenkinsWorld Choose Your Jenkins Distro Wisely (continued) • I like the LTS versions, but I wanted/needed the latest features – Alternatively, I could have upgraded the individual plugins for the new functionality sudo wget -O /etc/yum.repos.d/jenkins.repo http://pkg.jenkins- ci.org/redhat/jenkins.repo sudo rpm --import https://jenkins-ci.org/redhat/jenkins-ci.org.key sudo yum install jenkins sudo service jenkins start/stop/restart sudo chkconfig jenkins on curl localhost:8080 © 2016 CloudBees, Inc. All Rights Reserved
  • 13. #JenkinsWorld New Shell Step Syntax • Advanced configuration added – Now sh step can return the standard output to variable assignment – No longer need “sentinel” files © 2016 CloudBees, Inc. All Rights Reserved
  • 14. #JenkinsWorld New Stage Syntax • New syntax for stage definition: – “Using the ‘stage’ step without a block argument is deprecated” © 2016 CloudBees, Inc. All Rights Reserved
  • 15. #JenkinsWorld Today’s Jenkins Pipeline © 2016 CloudBees, Inc. All Rights Reserved
  • 16. #JenkinsWorld Pipeline Utilities • Use pipeline-utility-steps plugin – https://wiki.jenkins-ci.org/display/JENKINS/Pipeline+Utility+Steps+Plugin – https://jenkins.io/doc/pipeline/steps/pipeline-utility-steps/ • Setup tooling (Maven, Sonar, etc.) and reference this tooling in CPS © 2016 CloudBees, Inc. All Rights Reserved
  • 17. #JenkinsWorld Pipeline Calling AWS CLI • Watch your environment variables – If used, put exports in the same shell call as AWS CLI call (context) • Use the CloudBees Enterprise Jenkins AWS CLI Plugin – Or, create IAM user and use access key and secret keys, with withEnv construct – Or, use –-profile switch in AWS CLI call – Or, use EC2 roles and credentials from EC2 metadata – DANGEROUS!! – Or, set Jenkins AWS system-level configuration – Or, used combination of CloudBees AWS Credentials and Credential Binding Plugins © 2016 CloudBees, Inc. All Rights Reserved
  • 18. #JenkinsWorld CloudBees AWS Credentials Plugin © 2016 CloudBees, Inc. All Rights Reserved
  • 19. #JenkinsWorld CloudBees AWS CLI Plugin • https://go.cloudbees.com/docs/cloudbees-documentation/cje-user- guide/chapter-aws-cli.html • Uses pipeline build wrapper to wrap AWS CLI calls in environment with proper credentials. © 2016 CloudBees, Inc. All Rights Reserved
  • 20. #JenkinsWorld CloudBees AWS CLI Plugin © 2016 CloudBees, Inc. All Rights Reserved
  • 21. #JenkinsWorld Credentials Binding Plugin © 2016 CloudBees, Inc. All Rights Reserved
  • 22. #JenkinsWorld Jenkins Master System-Level AWS Configuration © 2016 CloudBees, Inc. All Rights Reserved cd /var/lib/jenkins sudo -u jenkins aws configure
  • 23. #JenkinsWorld AWS CLI - Create Test ENV Stage • Create EC2 instance from known AMI, Security group, Subnet, Key Pair, Role – Write JSON results to file – Slurp file to get InstanceId, PrivateIpAddress • Wait for instance to be “running” – Need InstanceId to call “wait” • Tag instance – Need InstanceId • Wait for instance to be reachable – Then configure instance using ssh and PrivateIpAddress © 2016 CloudBees, Inc. All Rights Reserved
  • 24. #JenkinsWorld AWS CLI - Create Test ENV Stage (continued) • Install tools (Java, Tomcat, etc.) • Install AWS CodeDeploy agent © 2016 CloudBees, Inc. All Rights Reserved
  • 25. #JenkinsWorld jq • Used in pipeline scripts to parse JSON using JMESPath • Use JMESPath (JSON Matching Expression path) Terminal (jpterm) to build paths – https://github.com/jmespath/jmespath.terminal sudo su – cd /usr/bin wget http://stedolan.github.io/jq/download/linux64/jq chmod +x ./jq © 2016 CloudBees, Inc. All Rights Reserved
  • 26. #JenkinsWorld AWS CodeCommit • Git repos in AWS • Requires credential helper in .gitconfig © 2016 CloudBees, Inc. All Rights Reserved git config --global credential.helper '!aws --profile JenkinsWorld2016 codecommit credential-helper $@’ git config --global credential.UseHttpPath true
  • 27. #JenkinsWorld AWS CodeCommit – AWS Temp Passwords • If you are using OSX with CodeCommit you need to be aware of the issue caused by AWS and your OSX Keychain utility – AWS uses a temporary that will cause a 403 error if your OSX Keychain is not configured properly – http://docs.aws.amazon.com/codecommit/latest/userguide/setting-up-https- unixes.html#setting-up-https-unixes-credential-helper – Temp Fix: security delete-internet-password -l git- codecommit.us-east-1.amazonaws.com © 2016 CloudBees, Inc. All Rights Reserved
  • 28. #JenkinsWorld AWS CodeCommit Repos © 2016 CloudBees, Inc. All Rights Reserved
  • 29. #JenkinsWorld AWS CodeDeploy • …is a set of ALM services • CodeDeploy is used to setup deployment resource targets, groups, and deployment configurations • Deploys to EC2 or ASG – Allows for rollback via redeploy • CodeDeploy Agent must be running on targets to receive deployments – Uses appspec.yml to customize deployment when the deployment package is delivered to the instance. © 2016 CloudBees, Inc. All Rights Reserved
  • 30. #JenkinsWorld CodeDeploy Packaging • Package artifacts to deploy via the CodeDeploy – This is a ZIP file with the artifacts as well as the YAML (*.yml) file needed for CodeDeploy automation © 2016 CloudBees, Inc. All Rights Reserved
  • 31. #JenkinsWorld AWS CodePipeline • Continuous Delivery Service • Uses CodeDeploy to target resources • Uses the concept of: – providers o Source, Deployment, Build, etc. – Workers – Actions • Can use S3 (GitHub, CodeCommit) as pipeline source – S3 bucket versioning is required – Lifecycle Management recommended • Can use Jenkins for build integration • AWS CLI call to create CodePipeline – Requires JSON config file © 2016 CloudBees, Inc. All Rights Reserved
  • 32. #JenkinsWorld CodeDeploy and CodePipeline Role Assumptions © 2016 CloudBees, Inc. All Rights Reserved
  • 33. #JenkinsWorld Timestamped Logs • timestamps { //code block } • Adds timestamped log entries • Adds additional UI control when reviewing logs. © 2016 CloudBees, Inc. All Rights Reserved
  • 34. #JenkinsWorld Best Practices and Possible Ideas • Jenkins SCM Sync Configuration Plugin • Bastion Hosts with SSH Forwarding – or centralized security (example: Centrify) • Groovy Sandbox and Script Approval – Look out for serialization issues – @NonCPS © 2016 CloudBees, Inc. All Rights Reserved
  • 35. #JenkinsWorld Possible Next Steps… • Move from Bastion host access to Centrify or similar tools. – Reduce compromised credentials, stop using key-pairs • Externalize scripts to shared libraries and Jenkinsfile – Keep your code DRY (Don’t Repeat Yourself) • Capture shell outputs to files to reduce noise in logs • Replace shell-script configurations with CloudFormation or Terraform • Add Chef or Ansible • Move from EC2 to ECS (if/when CodeDeploy works with ECS) • Move from master to Jenkins Agent node © 2016 CloudBees, Inc. All Rights Reserved
  • 36. #JenkinsWorld Final Thoughts… • There is a lot of room for improvement to the integration between Jenkins Pipeline and AWS – Plugins to be written and/or modified to be used with AWS resources • Jenkins Pipeline is the “DevOps Equalizer” – Instead of having to memorize the look and feel of many different plugins, CPS syntax and lexicon is required. – Programmers who have had a strong desire to use Jenkins are now re-empowered • I would really like to be able to disable sandbox=true for CpsScmFlowDefinition jobs. • I would really like to be able control the size of the CodeMirror script editor in the pipeline-job configuration screen © 2016 CloudBees, Inc. All Rights Reserved
  • 37. #JenkinsWorld #JenkinsWorld © 2016 CloudBees, Inc. All Rights Reserved Questions?
  • 38. #JenkinsWorld © 2016 CloudBees, Inc. All Rights Reserved
  • 39. #JenkinsWorld Parking Lot (If We Have Time) © 2016 CloudBees, Inc. All Rights Reserved
  • 40. #JenkinsWorld Pipeline Shared Libraries • https://github.com/jenkinsci/workflow-cps-global-lib- plugin/blob/master/README.md • Helps you keep your pipeline code DRY • Can use any GitRepo, even CodeCommit – https://github.com/cloudbees/jenkins-scripts/blob/master/pipeline-global-lib- init.groovy © 2016 CloudBees, Inc. All Rights Reserved
  • 41. #JenkinsWorld Pipelines That Have Lost Their Way • Occasionally, pipelines stop responding – They may even show that they were “aborted” – They are still ”spinning” • In the Global Security, disable “Prevent Cross Site Request Forgery exploits” • Then delete the job – $JENKINS_URL/job/${JOB_NAME}/${BUILD_NUMBER}/doDelete o Hit the “Try Posting” button if it appears o May need to disable “Prevent Cross Site Request Forgery exploits” in Global Security. • You may need to restart Jenkins: $JENKINS_URL/restart • Easier to handle since OSS version 2.21 © 2016 CloudBees, Inc. All Rights Reserved
  • 42. #JenkinsWorld Pipelines That Have Lost Their Way (continued) © 2016 CloudBees, Inc. All Rights Reserved

Notas do Editor

  1. Attribution: http://www.keepcalm-o-matic.co.uk/p/keep-calm-and-use-jenkins/
  2. Drawn with draw.io Make sure the EIP for the NAT Gateway is whitelisted to access the Test Server via the correct security group.
  3. Drawn with draw.io
  4. Example Red Hat install: Jenkins Only (https://wiki.jenkins-ci.org/display/JENKINS/Installing+Jenkins+on+Red+Hat+distributions) sudo wget -O /etc/yum.repos.d/jenkins.repo http://pkg.jenkins-ci.org/redhat-stable/jenkins.repo sudo rpm --import https://jenkins-ci.org/redhat/jenkins-ci.org.key sudo yum install jenkins sudo service jenkins start/stop/restart sudo chkconfig jenkins on curl localhost:8080
  5. Example Red Hat install: Jenkins Only (https://wiki.jenkins-ci.org/display/JENKINS/Installing+Jenkins+on+Red+Hat+distributions) sudo wget -O /etc/yum.repos.d/jenkins.repo http://pkg.jenkins-ci.org/redhat/jenkins.repo sudo rpm --import https://jenkins-ci.org/redhat/jenkins-ci.org.key sudo yum install jenkins sudo service jenkins start/stop/restart sudo chkconfig jenkins on curl localhost:8080
  6. https://groups.google.com/forum/#!topic/jenkinsci-users/MIVk-44cUcA
  7. https://groups.google.com/forum/#!topic/jenkinsci-users/MIVk-44cUcA
  8. Drawn with draw.io
  9. https://wiki.jenkins-ci.org/display/JENKINS/CloudBees+AWS+Credentials+Plugin
  10. http://stackshare.io/stackups/github-vs-gogs-vs-aws-codecommit sudo -u jenkins git config --global credential.helper '!aws codecommit credential-helper $@’ sudo -u jenkins git config --global credential.useHttpPath true sudo -u jenkins git config --global user.email "me@mycompany.com” sudo -u jenkins git config --global user.name "MyJenkinsServer"
  11. http://stackshare.io/stackups/github-vs-gogs-vs-aws-codecommit
  12. https://github.com/cloudbees/jenkins-scripts/blob/master/pipeline-global-lib-init.groovy https://wiki.jenkins-ci.org/display/JENKINS/SCM+Sync+configuration+plugin
  13. http://www.allthingsdistributed.com/2014/11/apollo-amazon-deployment-engine.html
  14. https://stelligent.com/2015/07/09/aws-codepipeline-released-and-there-was-much-rejoicing/ http://docs.aws.amazon.com/codepipeline/latest/userguide/pipeline-structure.html
  15. Attribution: http://cliparts.co/clipart/3665297
  16. http://www.programering.com/a/MDM4UjNwATY.html https://support.cloudbees.com/hc/en-us/articles/216436527-Unable-to-kill-a-Workflow-or-Pipline-job-that-is-stuck-executing
  17. http://www.programering.com/a/MDM4UjNwATY.html https://support.cloudbees.com/hc/en-us/articles/216436527-Unable-to-kill-a-Workflow-or-Pipline-job-that-is-stuck-executing