class: center, middle # Put the dev back into devops ### a cheap and easy guide to getting your changes into production ### Jon Johnson 
jrjohnson
jrjohnson_ --- # Who am I? - Full stack web developer - Technical lead for the Ilios Project open source curriculum management system for health science education. (http://iliosproject.org) - Ardently lazy about repeating tasks .center[] --- # Lets GIT cracking - What is git and why does it play such a critical role? - Distributed version control primer - client vs server - Git for humans (https://abookapart.com/products/git-for-humans) --- # Everything lives in the `.git` directory .center[DEMO TIME!] .center[] .footnote[http://giphy.com/gifs/demo-rollercoaster-wooden-r9CT85ZJah3Ik] ??? ``` bash cd ~/Desktop/gitdemo git init echo "Please Read me" > README git add README git commit ``` Open in finder and look at the file ``` bash git checkout -b edit-readme echo "Please Do NOT Read me" >> README git commit -a -m 'Better readme' ``` Open in finder and look at the file ``` bash git checkout -b delete-readme git rm README git commit -a -m 'Remove readme' ``` Switch between branches and look at the file in the finder --- # Remotes and Forks and Branches, oh My! - What to share and when / **Keep your crappy ideas private** --- # Why Fork and Pull? - Limited authority to make commits - Everyone has their own playground - Only master matters - short lived branches --- # Up to date forking - Never touch your master branch - `git pull --rebase upstream master` .center[] --- # Github FTW! - The repository is **in the *cloud*** - Public / Private repositories - Common tool makes onboarding easier .center[] --- # GitHub 2000: Pull Requests - Validate every change: - Unit tests - Code Style - Manual Validation - Checkout and review - Build and deploy the PR - Discussion on small features, screen shots, etc. .center[] --- # What can the internets do for you? .center[] .footnote[https://laughingsquid.com/i-can-has-cheezburger-the-musiclol/] --- # What can the internets do for you? - Github - Travis - Saucelabs (test in ALL THE BROWSERS) - Code Climate (code quality) - Coveralls (test coverage) - Heroku (deploy PRs for testing) --- # Travis for Continuous Integration - Free for open source - Configurable virtual testing dashboard - --- # AWS for continous delivery - S3 bucket stores files - Cloudfront serves assets - S3 stores a JSON description of index ```json { link: [ { rel: "stylesheet", href: "https://d26vzvixg52o0d.cloudfront.net/assets/vendor-fda2f842da2dc4fa03daaa1bd5411c9e.css" }, { rel: "stylesheet", href: "https://d26vzvixg52o0d.cloudfront.net/assets/ilios-ce71609f3b7baec15ff33a847fbe8f66.css" } ], script: [ { src: "https://d26vzvixg52o0d.cloudfront.net/assets/vendor-9c5092b47123cf8fa27e436e8e8fc608.js" }, { src: "https://d26vzvixg52o0d.cloudfront.net/assets/ilios-ca247ee9a3b36d2dce3689bc7edcab77.js" }, ] } ``` --- class: center, middle ### Questions?  Slides at: https://jrjohnson.dev/talks/2016-04-devops-process.html
jrjohnson
jrjohnson_