├── .gitignore
├── .gitmodules
├── LICENSE
├── README.md
├── accreditation
├── README.md
├── agile-methodology.md
├── aws-services
│ ├── basestyle.css
│ └── index.html
├── container-management-kubernetes.md
├── container-management-mesos.md
├── container-os-comparison.md
├── deep-dive-vagrant.md
├── devops-tools-vagrant-and-packer.md
├── docker-and-containers.md
├── git
│ ├── README.md
│ ├── git.md
│ ├── images
│ │ ├── github_compare.png
│ │ ├── github_compare2.png
│ │ ├── github_create_pr.png
│ │ ├── github_merge.png
│ │ ├── github_merge_successful.png
│ │ ├── github_new_branch.png
│ │ └── github_pr.png
│ ├── index.html
│ └── style.css
├── images
│ ├── Kubernetes overview.001.png
│ ├── Kubernetes overview.002.png
│ ├── Kubernetes overview.003.png
│ ├── Kubernetes overview.004.png
│ ├── kubernetes-graph-01.png
│ ├── kubernetes-install.png
│ ├── mesos.png
│ ├── open-source-companies.png
│ ├── rexray-advanced.png
│ ├── rexray-basic.png
│ ├── rexray-logo.jpg
│ ├── vagrant-windows.png
│ ├── what-is-infra.001.png
│ ├── what-is-infra.002.png
│ └── what-is-infra.003.png
├── infrastructure-as-code.md
├── intro-to-nosql.md
├── introduction-to-ci.md
├── microservices-and-service-discovery.md
├── modern-devops-style-communication-and-collaboration-tools.md
├── object-storage
│ ├── README.md
│ ├── images
│ │ ├── block.png
│ │ └── object.png
│ ├── index.html
│ ├── object-storage.md
│ └── style.css
├── open-source-is-good-for-business-and-humanity.md
├── project-rexray-and-modern-data-persistence.md
└── what-is-cf.md
├── devops-geekweek
├── 12_Factor_Apps_For_Ops.md
├── Day1-Part1-Tools.md
├── Day1-Part2-Agile101.md
├── Day2-Part1-Git.md
├── Day2-Part2-12factorApp.md
├── Day2-Part3-SprintPlanning.md
├── Day3-Part1-WhatIsCF.md
├── Day3-Part2-CFServices.md
├── Day3-Part3-BuildStuff.md
├── Day4-Part1-Logging.md
├── Day4-Part2-Instrumentation.md
├── Day5-Part1-DemosRetrospective.md
├── Homework.md
├── README.md
└── images
│ ├── Devops.png
│ ├── base.jpg
│ ├── basic.png
│ ├── bellichick.jpg
│ ├── concurrency.png
│ ├── configshuffle.png
│ ├── criticalerror.png
│ ├── deprecated.png
│ ├── gears.jpg
│ ├── github_compare.png
│ ├── github_compare2.png
│ ├── github_create_pr.png
│ ├── github_merge.png
│ ├── github_merge_successful.png
│ ├── github_new_branch.png
│ ├── github_pr.png
│ ├── incremental.png
│ ├── iterative.png
│ ├── loggly.png
│ ├── mvp_fail_01.png
│ ├── newrelicdash.png
│ ├── newrelicoverview.png
│ ├── newrelictrace.png
│ ├── obama.jpg
│ ├── pcfopsmanager.tiff
│ ├── petversuscattle.png
│ ├── profiles.jpg
│ ├── rca.jpg
│ ├── showcase.png
│ ├── speakers.jpg
│ ├── timebox.png
│ ├── title.jpg
│ ├── workedonmine.jpg
│ ├── worksonmymachine.png
│ └── yaml.jpg
├── docker-workshops
├── README.md
├── docker-platform-intro
│ ├── README.md
│ ├── lab1-your-first-container
│ │ └── README.md
│ ├── lab2-docker-compose
│ │ ├── Dockerfile
│ │ ├── app.py
│ │ ├── docker-compose.yml
│ │ ├── extends
│ │ │ ├── Dockerfile
│ │ │ ├── app.py
│ │ │ ├── common.yml
│ │ │ ├── docker-compose.yml
│ │ │ ├── production.yml
│ │ │ └── requirements.txt
│ │ └── requirements.txt
│ ├── lab3-docker-swarm
│ │ └── README.md
│ ├── lab4-coreos
│ │ ├── README.md
│ │ ├── multi-container-ha
│ │ │ └── apache@.service
│ │ └── one-container
│ │ │ └── ubuntu.service
│ └── presentations
│ │ ├── CoreOS 101 - December 2014 - Jonas Rosland.md
│ │ ├── Docker Compose and Panamax - June 2015 - Jonas Rosland.md
│ │ ├── Docker ecosystem.md
│ │ ├── Docker management overview - December 2014 - Jonas Rosland.md
│ │ ├── EMC CODE intro.md
│ │ ├── emccode-team.png
│ │ └── images
│ │ ├── docker-compose-hello-world.png
│ │ ├── docker-compose-hello-world2.png
│ │ ├── docker-compose-scale.png
│ │ ├── docker-compose-scale2.png
│ │ ├── docker-compose-scale3.png
│ │ └── lorry.io.png
└── docker-storage-networking
│ ├── README.md
│ ├── lab1-your-first-container
│ └── README.md
│ ├── lab2-create-a-compose-file
│ └── README.md
│ ├── lab3-create-a-swarm-cluster
│ └── README.md
│ ├── lab4-container-persistence
│ └── README.md
│ ├── lab5-networking-between-container-hosts
│ └── README.md
│ ├── prep
│ ├── README.md
│ ├── dockertraining.sh
│ ├── example
│ ├── rexconfig.yml
│ └── student.json
│ └── presentation.md
├── mesos-workshop
├── Apache-Mesos-Workshop-HandsOnLab.md
├── Apache-Mesos-Workshop-Part1.md
├── Apache-Mesos-Workshop-Part2.md
├── README.md
└── images
│ ├── Mesos Hosts.png
│ ├── Mesos application support.png
│ ├── Mesos-Users.png
│ ├── mesos frameworks.png
│ ├── mesos overview.png
│ ├── mesos paper screenshot.png
│ └── wired mesos screenshot.png
└── one-day-geekweek
├── agenda.md
├── images
├── Devops.png
├── base.jpg
├── basic.png
├── bellichick.jpg
├── byo.png
├── cna.png
├── cnpcomponents.png
├── concurrency.png
├── configshuffle.png
├── criticalerror.png
├── deprecated.png
├── gears.jpg
├── github_compare.png
├── github_compare2.png
├── github_create_pr.png
├── github_merge.png
├── github_merge_successful.png
├── github_new_branch.png
├── github_pr.png
├── incremental.png
├── iterative.png
├── loggly.png
├── mvp_fail_01.png
├── newrelicdash.png
├── newrelicoverview.png
├── newrelictrace.png
├── obama.jpg
├── pcf.png
├── pcfopsmanager.tiff
├── petversuscattle.png
├── profiles.jpg
├── rca.jpg
├── showcase.png
├── speakers.jpg
├── structurecomponents.png
├── timebox.png
├── title.jpg
├── traditionalapp.png
├── workedonmine.jpg
├── worksonmymachine.png
└── yaml.jpg
├── index.html
├── part1.md
├── part2.md
├── part3.md
├── part4.md
├── part5.md
├── part6.md
└── part7.md
/.gitignore:
--------------------------------------------------------------------------------
1 | .git
2 | .DS_Store
3 | *.pdf
4 |
--------------------------------------------------------------------------------
/.gitmodules:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/.gitmodules
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | Training modules from EMC {code}
2 | ================================
3 |
4 | Welcome to the official training modules from the {code} team. Here we will maintain all of our training material that we build ranging from general 101 level topics through advanced hands on workshops.
5 |
6 | ### Accreditation
7 |
8 | Here you will find all the DevOps-related quarterly accreditation training that we have created for EMC SEs and the general public.
9 |
10 | ### DevOps GeekWeek
11 |
12 | This is a 5-day class that Jonas Rosland and Matt Cowger are giving to interested individuals within EMC that want to go deeper and get hands on with developing applications in an Agile manner, focusing on 12-factor rules and running them on a Cloud Native platform.
13 |
14 | ### Docker Workshops
15 |
16 | These are a collection of comprehensive workshops including Docker platform tools ranging from introductory topics with advanced concepts including storage and networking.
17 |
18 | ### Maintainers
19 |
20 | Github|Twitter
21 | -----------|-----
22 | [@jrosland](https://github.com/jonasrosland)|[Jonas Rosland](https://twitter.com/jonasrosland)
23 | [@mcowger](https://github.com/mcowger)|[Matt Cowger](https://twitter.com/mcowger)
24 | [@kacole2](https://github.com/kacole2)|[Kendrick Coleman](https://twitter.com/kendrickcoleman)
25 |
--------------------------------------------------------------------------------
/accreditation/README.md:
--------------------------------------------------------------------------------
1 | # Accreditation Courses
2 |
3 | This folder contains everything related to the quarterly accreditation courses created by the EMC {code} community.
4 |
5 | Here are direct links to the accreditation course videos on YouTube:
6 |
7 | ## Q2 2016
8 | - [So You Want To Build An App](https://www.youtube.com/watch?v=0DO_rY3hER8&index=5&list=PLbssOJyyvHuWiBQAg9EFWH570timj2fxt)
9 | - [Overview Of The DevOps Periodic Table](https://www.youtube.com/watch?v=Anbm2G7zpW0&index=6&list=PLbssOJyyvHuWiBQAg9EFWH570timj2fxt)
10 | - [Open source is Good for Business and Humanity](https://www.youtube.com/watch?v=Pxn6YX8FjCM&index=7&list=PLbssOJyyvHuWiBQAg9EFWH570timj2fxt)
11 | - [Overview of AWS Services](https://www.youtube.com/watch?v=JopakKD3r8U&index=8&list=PLbssOJyyvHuWiBQAg9EFWH570timj2fxt)
12 |
13 | ## Q1 2016
14 | - [Source Control with Git](https://www.youtube.com/watch?v=NPEy4F_j5Hc&index=2&list=PLbssOJyyvHuWiBQAg9EFWH570timj2fxt)
15 | - [Object Storage](https://www.youtube.com/watch?v=1utJnYL28fo&index=4&list=PLbssOJyyvHuWiBQAg9EFWH570timj2fxt)
16 | - [Microservices and Service Discovery](https://www.youtube.com/watch?v=Q0hcKOa9Gq8&index=5&list=PLbssOJyyvHuWiBQAg9EFWH570timj2fxt)
17 | - [Container OS Comparisons](https://www.youtube.com/watch?v=sHFQbA7GWMc&index=6&list=PLbssOJyyvHuWiBQAg9EFWH570timj2fxt)
18 |
19 | ## Q4 2015
20 | - [Container Data Persistence presentation](http://kendrickcoleman.com/slides/containerpersistence/#/) and [video](https://www.youtube.com/watch?v=4o0WYS32x_E&index=7&list=PLbssOJyyvHuWiBQAg9EFWH570timj2fxt)
21 | - [Intro to NoSQL](https://www.youtube.com/watch?v=K326pO0Bh-o&list=PLbssOJyyvHuWiBQAg9EFWH570timj2fxt&index=3)
22 | - [Intro to Continuous Integration](https://www.youtube.com/watch?v=buXwBr9H3VY&list=PLbssOJyyvHuWiBQAg9EFWH570timj2fxt&index=4)
23 | - [Container Management - Mesos](https://www.youtube.com/watch?v=TkLPr3GexZU&list=PLbssOJyyvHuWiBQAg9EFWH570timj2fxt&index=6)
24 |
25 | ## Q3 2015
26 | - [DevOps Tools - Vagrant and Packer](https://www.youtube.com/watch?v=6-7WjA-hHvg&index=2&list=PLbssOJyyvHuWiBQAg9EFWH570timj2fxt)
27 | - [DevOps Tools - Cloud Foundry](https://www.youtube.com/watch?v=qr_gro2TCGU&index=6&list=PLbssOJyyvHuWiBQAg9EFWH570timj2fxt)
28 | - [Intro to Container Management and CoreOS](https://www.youtube.com/watch?v=-aQOGsHm_bo&index=8&list=PLbssOJyyvHuWiBQAg9EFWH570timj2fxt)
29 | - [Intro to Container Management and Kubernetes](https://www.youtube.com/watch?v=qCxYjq7EBHc&index=7&list=PLbssOJyyvHuWiBQAg9EFWH570timj2fxt)
30 |
31 | ## Q2 2015
32 | - [Infrastructure as Code](https://www.youtube.com/watch?v=jlEe70W9WoA&index=4&list=PLbssOJyyvHuWiBQAg9EFWH570timj2fxt)
33 | - [Introduction to Docker and Containers](https://www.youtube.com/watch?v=IEGPzmxyIpo&index=3&list=PLbssOJyyvHuWiBQAg9EFWH570timj2fxt)
34 | - [Intro to Agile Methodology](https://www.youtube.com/watch?v=78jdpP3jw4A&index=9&list=PLbssOJyyvHuWiBQAg9EFWH570timj2fxt)
35 | - [Modern DevOps Communication and Collaboration Tools](https://www.youtube.com/watch?v=khMbosLRuFo&index=5&list=PLbssOJyyvHuWiBQAg9EFWH570timj2fxt)
36 |
--------------------------------------------------------------------------------
/accreditation/agile-methodology.md:
--------------------------------------------------------------------------------
1 | # Agile Methodology
2 | ## 2015 Q2 EMC Accreditation
3 | ## Jonas Rosland & Matt Cowger
4 |
5 | ---
6 |
7 | # Agile 101
8 |
9 | > You can't gather all the requirements up front
10 | The requirements you do gather **will** change
11 | There is always more to do than time and money will allow
12 |
13 | -- The Agile Samurai, J. Rasmusson
14 |
15 | ^ Open this presentation with [Deckset](http://www.decksetapp.com/). Just keep this in mind as we go through this, as its the underpinning of everything here.
16 |
17 | ---
18 |
19 | # How bad is it?
20 |
21 | > 18% of software projects are considered "failed", 43% "challenged"
22 |
23 | > 39% actually succeeding
24 |
25 | -- 2012 study by [The Standish Group](http://www.versionone.com/assets/img/files/CHAOSManifesto2013.pdf)
26 |
27 | ^ So whats actually driving this? Why are companies flocking to agile methods? Its because the current methods aren't working - they aren't scaling.
28 |
29 | ---
30 |
31 | # What can happen without Agile?
32 |
33 | * Software projects aren't delivered on time to market
34 | * Requirements not met with high cost to make changes after delivery
35 | * Having to “get it right” first time/up front is really hard
36 |
37 | ---
38 |
39 | # Unhappy Customers and Developers
40 | 
41 |
42 | ---
43 |
44 | # Software Development Methodologies
45 | * "Code-fix” (or no process)
46 | * Structured, heavy weight methodologies a.k.a.
47 | “Plan Driven Methodologies” and “Waterfall”
48 |
49 | ^ If you dont have any real process at all, you have a code-fix process, wherein you 'write code' then 'fix it' repeatedly. Perhaps you are beyond that, and you've gone to a process where you gather requirements, and follow a very specific methodlogy....If so, its probably a variant of waterfall.
50 |
51 | ---
52 |
53 | # Traditional Waterfall Process
54 |
55 | ---
56 |
57 | 
58 |
59 | ---
60 |
61 | # Waterfall Methodology
62 |
63 | * Largely influenced by _traditional engineering_ and _quality processes_ in industries
64 | * Desire to make software development more _predictable_, _measurable_ and _efficient_
65 | * Strong emphasis on _detailed planning_ and then _executing to the plan_
66 |
67 | ---
68 |
69 | # But Software is Different
70 |
71 | * Is not tangible
72 | * Is not based on mathematics
73 | * Needs knowledge workers
74 |
75 | ^ Its far too fluid and changing compared to math or engineering, and knowledge workers aren't a fungible resource!
76 |
77 | ---
78 |
79 | # Relevance
80 | ###Heavy weight methodologies are most successful when:
81 |
82 | - Requirements are stable
83 | - Technology is well known and mature
84 | - Everything happens as one would expect
85 | - We are not taking on anything new or unknown
86 | - Coding is ‘copy and paste’
87 |
88 | ---
89 |
90 | # That's just not true for most modern projects
91 |
92 | ---
93 |
94 | # Origins Of Agile
95 |
96 | ###Agile Methods are a reaction to:
97 |
98 | * Rigidity of heavy weight methods
99 | * Bureaucracy introduced by heavy weight methods
100 | * Unpleasant surprises due to lack of visibility
101 | * **The myth that a well defined process is more valuable than the people who use it**
102 |
103 | ---
104 |
105 | # Agile Follows Systems Thinking
106 | * System Thinking is a way of looking at how things influence each other as a whole and not as individual parts
107 | * Focus on Flow, not Function
108 | * Look at the end-to-end process and the value we deliver to our customers
109 | * What do our customers value
110 | * How do we respond to the demands from our customers, as a system
111 |
112 | ---
113 |
114 | # Agile Follows Lean Thinking
115 | * Add nothing but value (eliminate waste)
116 | * Flow value from demand (delay commitment)
117 | * Minimize inventory (minimize intermediate artifacts)
118 | * Optimize across the organization
119 |
120 | ^ this originally comes from the manfacturing world, lest you think it doesn't apply outside software development.
121 |
122 | ---
123 |
124 | 
125 |
126 | ---
127 |
128 | # The Agile Manifesto
129 |
130 | ---
131 |
132 | >We are uncovering better ways of developing software by doing it and helping others do it. Through this work we have come to value:
133 |
134 | * **Individuals and interactions** over _processes and tools_
135 | * **Working software** over _comprehensive documentation_
136 | * **Customer collaboration** over _contract negotiation_
137 | * **Responding to change** over _following a plan_.
138 |
139 | >That is, while there is value in the items on _the right_,
140 | we value the **items on the left** more.
141 |
142 | ---
143 |
144 | #12 Principles of Agile
145 |
146 | * Our highest priority is to satisfy the customer through early and continuous delivery of valuable software.
147 | * Welcome changing requirements, even late in development.
148 | * Deliver working software frequently, with a preference to the shorter timescale.
149 |
150 | ^ customer needs are the most important.
151 | ^ late requirements are OK if we can handle them without friction
152 | ^ minimum viable product. working partially the wrong way is better than non working perfection.
153 |
154 | ---
155 |
156 | #12 Principles of Agile (cont)
157 |
158 | * Business people and developers must work together throughout the project.
159 | * Build projects around motivated individuals. Give them the environment and support they need, and trust them to get the job done.
160 | * The most efficient and effective method of conveying information is face-to-face conversation.
161 |
162 | ^ If biz+devs dont work together, they dont align on goals. In EMC, we call this 'compensation drives behavior'
163 | ^ *people* are at the center, and will drive happy teams. This comes form the ground up, not top down.
164 | ^ nothing is better than standing in front of each other. video conferences as a next best.
165 |
166 | ---
167 |
168 | #12 Principles of Agile (cont)
169 |
170 | * Working software is the primary measure of progress.
171 | * Agile processes promote sustainable development. The sponsors, developers, and users should be able to maintain a constant pace indefinitely.
172 | * Continuous attention to technical excellence and good design enhances agility.
173 |
174 | ^ working > *
175 | ^ prevent heros. heros are bad because they burn out. (mention phoenix project)
176 | ^ avoid technical debt.
177 |
178 | ---
179 |
180 | #12 Principles of Agile (cont)
181 |
182 | * Simplicity - the art of maximizing the amount of work not done - is essential.
183 | * The best architectures, requirements, and designs emerge from self-organizing teams.
184 | * At regular intervals, the team reflects on how to become more effective, then tunes and adjusts its behaviour accordingly.
185 |
186 | ^ simplicity also drives the ability to change quickly.
187 | ^ teams building, not highlevel arch teams, determine the best methods.
188 | ^ agile itself is iterated.
189 |
190 | ---
191 |
192 | # Minimum Viable Product (MVP)
193 |
194 | 
195 |
196 | ^ In this example, we build 5 new products...does that possibly take more overall work? Maybe, but we make revenue the WHOLE TIME, not just after step 4, when its expensive to fail.
197 |
198 | ---
199 |
200 | # Agile Myths
201 |
202 | * No Planning
203 | * No Documentation
204 | * Lacks Discipline
205 | * Limited to Co-Located Teams
206 | * Open Ended
207 |
208 | ^ There's a ton of planning, its just done for shorter time frames
209 | ^ There's documentation in all of the discussions done by the team in the Kanban boards and the code. The lack of a 'master plan' is a positive.
210 | ^ It requires more discipline to follow this and trust your team...
211 | ^ Colocated teams are easier (especially newbies), but remote teams can be done with modern tools (look for our other course)
212 | ^ Agile is indeed open ended, in that we are always looking to iterate. Its not open ended with working software, which is delivered at the end of every sprint. We only commit to what we can finish.
213 |
214 | ---
215 |
--------------------------------------------------------------------------------
/accreditation/container-management-kubernetes.md:
--------------------------------------------------------------------------------
1 | # Container Management: Kubernetes
2 | ### 2015 Q3 EMC Accreditation
3 | ### Jonas Rosland (@jonasrosland) &
4 | ### Matt Cowger (@mcowger)
5 |
6 | ---
7 |
8 | > Kubernetes
9 | > Greek for "pilot" or "Helmsman of a ship"
10 |
11 | ---
12 |
13 | # koo-ber-nay'-tace
14 | ## Container management at scale
15 |
16 | ---
17 |
18 | ## Manage a cluster of Linux containers as a single system to accelerate Dev and simplify Ops
19 |
20 | ---
21 |
22 | # Why do you need a container manager?
23 |
24 | Similar to why you would need a manager for
25 | - Windows and Windows apps
26 | - Linux and Linux apps
27 | - VMware and Virtual Machines
28 |
29 | Containers are a simple way of packaging apps
30 |
31 | ---
32 |
33 | # What is it?
34 |
35 | An open source container orchestration system
36 |
37 | Runs Docker containers
38 |
39 | Supports multiple cloud and bare-metal deployments
40 |
41 | Made to manage **applications**, not machines
42 |
43 | Automatic placement of containers (similar to VMware DRS)
44 |
45 | ---
46 |
47 | 
48 |
49 | ---
50 |
51 | # Kubernetes concepts
52 |
53 | ---
54 |
55 | # Container
56 |
57 | Sealed application package (Docker)
58 |
59 | 
60 |
61 | ---
62 |
63 | # Clusters
64 |
65 | The compute resources on top of which your containers are built
66 |
67 | Kubernetes can run anywhere!
68 |
69 | 
70 |
71 | ---
72 |
73 | # Pods
74 |
75 | Small group of Docker containers that work together
76 |
77 | The smallest deployable unit that can be created, scheduled, and managed with Kubernetes
78 |
79 | Example: web server and a content syncer
80 |
81 | 
82 |
83 | ---
84 |
85 | # Replication controllers
86 |
87 | Ensures that a specified number of pods are running at any given time
88 |
89 | Creates or kills pods as required
90 |
91 | If you want to have 4 copies of something running, that's the desired state
92 |
93 | The RCs always make sure to get to the desired state
94 |
95 | ---
96 |
97 | # Services
98 |
99 | A set of pods that work together
100 |
101 | Example: load-balanced backends
102 |
103 | ---
104 |
105 | # Labels
106 |
107 | Used to organize and select groups of objects based on **key:value** pairs.
108 |
109 | Examples:
110 | ```
111 | role: frontend
112 | vs
113 | role: backend
114 | ```
115 |
116 | ---
117 |
118 | # So to put it all together
119 |
120 | Containers run on clusters
121 |
122 | Pods are containers that work together
123 |
124 | Services are pods that work together
125 |
126 | Labels are used to organize services
127 |
128 | ---
129 |
130 | 
131 |
132 | ---
133 |
134 | 
135 |
136 | ---
137 |
138 | 
139 |
140 | ---
141 |
142 | 
143 |
144 | ---
145 |
146 | # For more information:
147 |
148 | http://kubernetes.io
149 |
150 | https://github.com/googlecloudplatform/kubernetes
151 |
152 | https://www.digitalocean.com/community/tutorials/an-introduction-to-kubernetes
153 |
--------------------------------------------------------------------------------
/accreditation/container-management-mesos.md:
--------------------------------------------------------------------------------
1 | # Container Management: Mesos
2 | ### 2015 Q4 EMC Accreditation
3 | ### Jonas Rosland (@jonasrosland) &
4 | ### Matt Cowger (@mcowger)
5 |
6 | ---
7 |
8 | > Program against your datacenter like it’s a single pool of resources
9 |
10 | ---
11 |
12 | # Apache Mesos
13 |
14 | Abstracts CPU, memory, storage, and other compute resources
15 |
16 | Enables fault-tolerant and elastic distributed systems
17 |
18 | Part of the Apache Software Foundation
19 |
20 | ---
21 |
22 | # Mesos features
23 |
24 | Scalability to 10,000s of nodes
25 |
26 | Fault-tolerant replicated master and slaves using ZooKeeper
27 |
28 | Support for Docker containers
29 |
30 | Native isolation between tasks with Linux Containers
31 |
32 | ---
33 |
34 | # Mesos features (cont)
35 |
36 | Multi-resource scheduling (memory, CPU, disk, and ports)
37 |
38 | Java, Python and C++ APIs for developing new parallel applications
39 |
40 | Web UI for viewing cluster state
41 |
42 | ---
43 |
44 | 
45 |
46 | ---
47 |
48 | # Marathon
49 |
50 | A cluster-wide init and control system for services in cgroups or Docker containers
51 |
52 | Built by Mesosphere
53 |
54 | Generally considered easier to start with than Apache Aurora
55 |
56 | ---
57 |
58 | 
59 |
60 | ---
61 |
62 | ```json
63 | {
64 | "id": "nginx",
65 | "container": {
66 | "docker": {
67 | "image": "million12/nginx",
68 | "network": "BRIDGE",
69 | "portMappings": [
70 | { "containerPort": 80, "hostPort": 0, "protocol": "tcp"}
71 | ],
72 | "parameters": [
73 | { "key": "volume-driver", "value": "rexray" },
74 | { "key": "volume", "value": "nginx-data:/data/www" }
75 | ]
76 | }
77 | },
78 | "cpus": 0.2,
79 | "mem": 32.0,
80 | "instances": 1
81 | }
82 | ```
83 |
84 | ---
85 |
86 | # Chronos
87 |
88 | A fault tolerant job scheduler for Mesos which handles dependencies and ISO8601 based schedules
89 |
90 | Originally built by AirBnB to replace cron
91 |
92 | Used for job orchestration
93 |
94 | ---
95 |
96 | 
97 |
98 | ---
99 |
100 | # Demo
101 |
102 | ---
103 |
104 | # So who uses Mesos?
105 |
106 | ---
107 |
108 | # Mesos users
109 |
110 | AirBnB, Apple, Cern, Cisco, Coursera, eBay, Ericsson, Foursquare, Hubspot
111 |
112 | Netflix, PayPal, Twitter, Uber, UC Berkeley, Yelp
113 |
114 | And a lot more!
115 |
116 | http://mesos.apache.org/documentation/latest/powered-by-mesos/
117 |
118 | ---
119 |
120 | # Try it out!
121 |
122 | https://github.com/mesosphere/playa-mesos
123 |
124 | https://github.com/jonasrosland/vagrant-mesos
125 |
126 | ---
127 |
128 | # More info
129 |
130 | http://mesos.apache.org/
131 |
132 | https://mesosphere.github.io/marathon/
133 |
134 | https://mesos.github.io/chronos/
135 |
--------------------------------------------------------------------------------
/accreditation/container-os-comparison.md:
--------------------------------------------------------------------------------
1 | # Container OS Comparison
2 | ### 2016 Q1 EMC Accreditation
3 | ### Jonas Rosland (@jonasrosland) &
4 | ### Matt Cowger (@mcowger)
5 |
6 | ---
7 |
8 | # Common questions
9 | > “Which is the best OS to run containers?”
10 | > “Is it CoreOS? What about RedHat? I’ve also heard about something called RancherOS?”
11 |
12 | Similar to the “Which Hypervisor is the best?” question
13 | The answer is as always “it depends”
14 |
15 | ---
16 |
17 | # What are the differences?
18 |
19 | ---
20 |
21 | 
22 |
23 | ---
24 |
25 | # [CoreOS](https://coreos.com/)
26 |
27 | - Focuses on large-scale deployments, mostly targeting enterprises
28 | - Hundreds of contributors and over 500 IRC users in [#coreos on FreeNode](https://botbot.me/freenode/coreos/)
29 | - It comes bundled with interesting tools developed by the CoreOS team, such as etcd, fleet, and flannel
30 | - Great starting points to understand the concepts of service discovery, resource scheduling, and container networking
31 | - Auto-updates the OS and keeps an old version for rollback use cases
32 |
33 | ---
34 |
35 | 
36 |
37 | ---
38 |
39 | 
40 |
41 | ---
42 |
43 | # [CoreOS - Tectonic](https://tectonic.com/)
44 | - A joint venture by CoreOS and Google
45 | (Google Ventures is also an investor in CoreOS)
46 | - An interesting way of getting CoreOS running with Kubernetes quickly and efficiently
47 | - Tectonic is a commercial Kubernetes platform, which can be important if you’re looking for more than community support when running large-scale containers in production
48 |
49 | ---
50 |
51 | 
52 |
53 | ---
54 |
55 | # [RancherOS](http://rancher.com/rancher-os/)
56 |
57 | - Takes what a container OS should be to the next step
58 | - Everything in RancherOS is a Docker container
59 | - A system Docker runs as PID 1 for system services
60 | - A user Docker runs all the user containers
61 | - Very lightweight, only 20MB
62 |
63 | ---
64 |
65 | 
66 |
67 | ---
68 |
69 | # [Rancher](http://rancher.com/rancher/) on RancherOS
70 |
71 | Adds several functions on top of the OS, such as
72 | - Resource management
73 | - Container networking
74 | - Service discovery
75 | - Load balancing
76 | - Health checks and recovery
77 | - and more
78 |
79 | ---
80 |
81 | # Snappy Ubuntu Core
82 | 
83 |
84 | ---
85 |
86 | # [Snappy Ubuntu Core](https://developer.ubuntu.com/en/snappy/)
87 |
88 | - Launched by Canonical in 2014
89 | - Comes with a new application manager (“**snappy**”) that focuses on installing and running both apps and containers.
90 | - Apps live in read-only images (similar to container images)
91 | - Apps can be transactionally updated
92 | - Also an interesting base OS for containers themselves
93 |
94 | ---
95 |
96 | 
97 |
98 | ---
99 |
100 | ## [RedHat Project Atomic](http://www.projectatomic.io/)
101 |
102 | - Built using upstream RPMs from CentOS, Fedora, and RHEL, and enables what RedHat calls “atomic” upgrades and rollback
103 | - Up to the admin to choose the base OS
104 | - Built-in functions for Docker, flannel, Kubernetes
105 | - Transactional OS update system, similar to CoreOS
106 |
107 | ---
108 |
109 | 
110 |
111 | ---
112 |
113 | # [Mesosphere DCOS](https://mesosphere.com/)
114 |
115 | - A robust and innovative way of looking at how to manage large-scale deployments of resources and applications
116 | - Built using the open source projects Apache Mesos, Marathon, Zookeeper
117 | - Added enterprise features and functionality for containers and Big Data pipelines
118 | - Automatically handles failover for applications
119 | - Support for stateful scaleout services like Cassandra
120 |
121 | ---
122 |
123 | 
124 |
125 | ---
126 |
127 | # [VMware Photon OS](https://vmware.github.io/photon/)
128 |
129 | - Announced and released in April
130 | - The first part of an ongoing open-source effort called the VMware Photon Platform
131 | - Minimal OS meant to be used with VMware technologies such as VMFork
132 | - Compatible with container runtimes Docker, rkt and Pivotal Garden
133 |
134 | ---
135 |
136 | # Learn more
137 |
138 | - Try them locally on your laptop or in a cloud environment
139 | - Docker workshops can be found at
140 | [https://github.com/emccode/training](https://github.com/emccode/training)
141 | - [Container management and CoreOS accreditation module](https://www.youtube.com/watch?v=-aQOGsHm_bo&index=8&list=PLbssOJyyvHuWiBQAg9EFWH570timj2fxt)
142 | - [Mesos accreditation module](https://www.youtube.com/watch?v=TkLPr3GexZU&list=PLbssOJyyvHuWiBQAg9EFWH570timj2fxt&index=6)
143 | - [Kubernetes accreditation module](https://www.youtube.com/watch?v=qCxYjq7EBHc&index=7&list=PLbssOJyyvHuWiBQAg9EFWH570timj2fxt)
144 | - Microservices and Service Discovery accreditation module
145 |
--------------------------------------------------------------------------------
/accreditation/deep-dive-vagrant.md:
--------------------------------------------------------------------------------
1 | # Deep Dive: Vagrant
2 | ### 2016 Q3 EMC Accreditation
3 | ### Jonas Rosland (@jonasrosland) &
4 | ### Matt Cowger (@mcowger)
5 |
6 | 
7 |
8 | ---
9 |
10 | # Recap: Vagrant
11 |
12 | Create and configure lightweight, reproducible, and portable development environments.
13 |
14 | Boot up entire configured systems in minutes.
15 |
16 | Run them anywhere!
17 |
18 | ---
19 |
20 | # Basic Vagrantfile
21 |
22 | ```
23 | Vagrant.configure("2") do |config|
24 | config.vm.box = "hashicorp/precise64"
25 | end
26 | ```
27 |
28 | ---
29 |
30 | # Vagrant boxes
31 |
32 | Many to choose from, have a look at http://vagrantbox.es
33 | - CentOS
34 | - SLES
35 | - Debian/Ubuntu
36 | - FreeBSD
37 | - Arch
38 | - Windows!
39 |
40 | ---
41 |
42 | # Windows on Vagrant
43 |
44 | Officially supported images can be found at
45 | https://developer.microsoft.com/en-us/microsoft-edge/tools/vms/
46 |
47 | 
48 |
49 | ---
50 |
51 | # Create a new Vagrant environment
52 |
53 | Add a new Vagrant box
54 |
55 | ```
56 | vagrant box add win8.1 http://aka.ms/vagrant-win81-ie11
57 | ```
58 |
59 | Initialize and run a new Vagrant environment
60 |
61 | ```
62 | vagrant init win8.1
63 | ```
64 |
65 | ```
66 | vagrant up
67 | ```
68 |
69 | ---
70 |
71 | # Demo!
72 |
73 | ---
74 |
75 | # Synced folders
76 |
77 | By default, `/vagrant` in the VM is the base directory where your `Vagrantfile` is
78 |
79 | ```
80 | $ vagrant up
81 | ...
82 | $ vagrant ssh
83 | ...
84 | vagrant@precise64:~$ ls /vagrant
85 | Vagrantfile
86 | script.sh
87 | README.md
88 | ```
89 |
90 | ---
91 |
92 | # Be careful with synced folders!
93 |
94 | If you remove something from `/vagrant`, it's deleted in your base directory as well
95 |
96 | ```
97 | vagrant@precise64:~$ ls /vagrant
98 | Vagrantfile
99 | script.sh
100 | README.md
101 | vagrant@precise64:~$ rm /vagrant/Vagrantfile
102 | vagrant@precise64:~$ exit
103 | $ ls
104 | script.sh
105 | README.md
106 | ```
107 |
108 |
109 | ---
110 |
111 | # Install and configure apps/services
112 |
113 | There are multiple ways of installing apps and services in your Vagrant VMs
114 |
115 | - Scripts (bash, PowerShell)
116 | - Ansible
117 | - Puppet
118 | - Chef
119 | - etc
120 |
121 | ---
122 |
123 | # Example of bash scripting - 1
124 |
125 | ```
126 | Vagrant.configure("2") do |config|
127 | config.vm.box = "hashicorp/precise64"
128 | config.vm.provision "shell",
129 | inline: "apt-get install apache2 -y"
130 | end
131 | ```
132 |
133 | ---
134 |
135 | # Example of bash scripting - 2
136 |
137 | install-apache.sh:
138 |
139 | ```
140 | #!/bin/bash
141 | apt-get install apache2 -y
142 | echo "
Hello from Vagrant
" > /var/www/index.html
143 | ```
144 | Vagrantfile:
145 |
146 | ```
147 | Vagrant.configure("2") do |config|
148 | config.vm.box = "hashicorp/precise64"
149 | config.vm.provision :shell, path: "install-apache.sh"
150 | end
151 | ```
152 |
153 | ---
154 |
155 | # Demo!
156 |
157 | ---
158 |
159 | # Port forwarding
160 |
161 | Forward localhost:8080 to vm:80, so we can access services
162 |
163 | ```
164 | Vagrant.configure("2") do |config|
165 | config.vm.box = "hashicorp/precise64"
166 | config.vm.provision :shell, path: "install-apache.sh"
167 | config.vm.network :forwarded_port, guest: 80, host: 8080
168 | end
169 | ```
170 |
171 | ---
172 |
173 | # Multiple VMs
174 |
175 | ```
176 | Vagrant.configure("2") do |config|
177 | config.vm.define "web" do |web|
178 | web.vm.box = "hashicorp/precise64"
179 | web.vm.provision :shell, path: "install-apache.sh"
180 | web.vm.network :forwarded_port, guest: 80, host: 8080
181 | end
182 |
183 | config.vm.define "db" do |db|
184 | db.vm.box = "hashicorp/precise64"
185 | db.vm.provision :shell, path: "install-mysql.sh"
186 | db.vm.network :forwarded_port, guest: 3306, host: 33306
187 | end
188 | end
189 |
190 | ```
191 |
192 | ---
193 |
194 | # Connecting to multiple VM setups
195 |
196 | ```
197 | $vagrant ssh web
198 | ...
199 | vagrant@web:~$
200 | ```
201 |
202 | ```
203 | $vagrant ssh db
204 | ...
205 | vagrant@db:~$
206 | ```
207 |
208 | ---
209 |
210 | # Customize the VMs
211 |
212 | ```
213 | Vagrant.configure("2") do |config|
214 | config.vm.box = "hashicorp/precise64"
215 | config.vm.provision :shell, path: "install-apache.sh"
216 | config.vm.network :forwarded_port, guest: 80, host: 8080
217 |
218 | config.vm.provider "virtualbox" do |v|
219 | v.memory = 2048
220 | v.cpus = 2
221 | end
222 | end
223 | ```
224 |
225 | ---
226 |
227 | # Demo!
228 |
229 | ---
230 |
231 | # Summary
232 |
233 | - Use Vagrant to easily set up test environments
234 | - Share your Vagrantfiles and scripts so anyone can use them
235 | - Create your own demos!
236 |
237 | ---
238 |
239 | # For more information
240 |
241 | http://vagrantup.com
242 |
243 | http://vagrantbox.es
244 |
245 | http://github.com/emccode/vagrant
246 |
--------------------------------------------------------------------------------
/accreditation/devops-tools-vagrant-and-packer.md:
--------------------------------------------------------------------------------
1 | # DevOps tools: Vagrant and Packer
2 | ### 2015 Q3 EMC Accreditation
3 | ### Jonas Rosland (@jonasrosland) &
4 | ### Matt Cowger (@mcowger)
5 |
6 | ---
7 |
8 | # Hashicorp
9 |
10 | 
11 |
12 | ---
13 |
14 | # Hashicorp
15 |
16 | Founded in 2012
17 |
18 | Creates Open Source software like:
19 | - Vagrant
20 | - Packer
21 | - Serf
22 | - Consul
23 | - Terraform
24 | - Vault
25 |
26 | ---
27 |
28 | 
29 |
30 | ---
31 |
32 | # Vagrant
33 |
34 | Create and configure lightweight, reproducible, and portable development environments.
35 |
36 | Boot up entire configured systems in minutes.
37 |
38 | Run them anywhere!
39 |
40 | ---
41 |
42 | # Vagrant will change how you work
43 |
44 | Install Vagrant on Windows, OS X or Linux
45 |
46 | Create a single file to describe the type of machine you want
47 |
48 | Run a single command
49 |
50 | ---
51 |
52 | # Vagrantfile
53 |
54 | ```
55 | Vagrant.configure("2") do |config|
56 | config.vm.box = "hashicorp/precise32"
57 | end
58 | ```
59 |
60 | ---
61 |
62 | # Run Vagrant
63 |
64 | ```
65 | vagrant up
66 | ```
67 |
68 | ---
69 |
70 | # Demo!
71 |
72 | ---
73 |
74 | # Three-node ScaleIO cluster demo!
75 |
76 | ```
77 | git clone https://github.com/jonasrosland/vagrant-scaleio
78 | cd vagrant-scaleio
79 | vagrant up
80 | ```
81 |
82 | ---
83 |
84 | 
85 |
86 | ---
87 |
88 | # Packer
89 |
90 | ### A tool for creating identical machine images for multiple platforms from a single source configuration
91 |
92 | ---
93 |
94 | # Packer
95 |
96 | Packer is easy to use and automates the creation of any type of machine image
97 |
98 | Embraces modern configuration management
99 |
100 | Encouraging you to use automated scripts to install and configure everything
101 |
102 | Packer brings machine images into the modern age, unlocking untapped potential and opening new opportunities
103 |
104 | 
105 |
106 | ---
107 |
108 | # Packer images
109 |
110 | Build images for Amazon EC2, DigitalOcean, Google Compute Engine, QEMU, VirtualBox, VMware, and more
111 |
112 | Support for more platforms is on the way, and anyone can add new platforms via plugins
113 |
114 | 
115 |
116 | ---
117 |
118 | # Packer benefits
119 |
120 | Use it in a continuous delivery pipeline
121 |
122 | Parity between dev and prod - all images are the same
123 |
124 | Create demos and appliances
125 |
126 | ---
127 |
128 | # For more information
129 |
130 | hashicorp.com
131 |
132 | vagrantup.com
133 |
134 | packer.io
135 |
--------------------------------------------------------------------------------
/accreditation/docker-and-containers.md:
--------------------------------------------------------------------------------
1 | # Docker and Containers
2 | ## 2015 Q2 EMC Accreditation
3 | ## Jonas Rosland & Matt Cowger
4 |
5 | ---
6 |
7 | # Apps have fundamentally changed
8 |
9 | ---
10 |
11 | # A decade ago (and still true for many)
12 |
13 | Apps were monolithic
14 |
15 | Built on a single stack such as .NET or Java
16 |
17 | Long lived
18 |
19 | Deployed to a single server
20 |
21 | ---
22 |
23 | 
24 |
25 | ---
26 |
27 | # Perhaps it was loadbalanced, but still monolithic
28 |
29 | ---
30 |
31 | 
32 |
33 | ---
34 |
35 | # Today
36 |
37 | Apps are constantly developed
38 |
39 | New versions are being deployed often
40 |
41 | Built from loosely coupled components
42 |
43 | Deployed to a multitude of servers
44 |
45 | ---
46 |
47 | 
48 |
49 | ---
50 |
51 | # How do you handle all these parts?
52 |
53 | ---
54 |
55 | # Let's start with a useful analogy
56 |
57 | ---
58 |
59 | # You're a shipping company
60 |
61 | ---
62 |
63 | # You ship pianos
64 |
65 | 
66 |
67 | ---
68 |
69 | # You're great at it
70 |
71 | ---
72 |
73 | # Then a customer wants to use you to ship potatoes as well
74 |
75 | ---
76 |
77 | # You say "Ok, they'll fit next to the pianos"
78 |
79 | ---
80 |
81 | 
82 | 
83 |
84 | ---
85 |
86 | # Then another customer wants you to ship whiskey
87 |
88 | ---
89 | 
90 | 
91 |
92 | ---
93 |
94 | # Things start to break when the whiskey spills all over the piano
95 |
96 | ---
97 |
98 | # And your crew is wondering how to handle all the differences
99 |
100 | ---
101 |
102 | # Size of goods
103 |
104 | ---
105 |
106 | # Form of goods
107 |
108 | ---
109 |
110 | # Requirements to keep it safe and stable during transport
111 |
112 | ---
113 |
114 | # Being able to transport it using different transport methods
115 |
116 | ---
117 |
118 | # So what to do?
119 |
120 | ---
121 |
122 | # Enter, the Intermodal container
123 |
124 | ---
125 |
126 | 
127 |
128 | ---
129 |
130 | # Now you can ship everything!
131 |
132 | 
133 |
134 | ---
135 |
136 | 
137 |
138 | ---
139 |
140 | 
141 |
142 | ---
143 |
144 | # So what does this have to do with software?
145 |
146 | ---
147 |
148 | # Well, it's similar
149 |
150 | ---
151 |
152 | # You have an app built out of a lot of small parts
153 |
154 | ---
155 |
156 | # These small parts are called micro services
157 |
158 | ---
159 |
160 | 
161 |
162 | ---
163 |
164 | 
165 |
166 | ---
167 |
168 | 
169 |
170 | ---
171 |
172 | 
173 |
174 | ---
175 |
176 | # You can surely install it in a production datacenter
177 |
178 | ---
179 |
180 | # But would it look the same if you ran it in your dev environment?
181 |
182 | ---
183 |
184 | # What about in a lab?
185 |
186 | ---
187 |
188 | # Or in the cloud somewhere?
189 |
190 | ---
191 |
192 | # Enter, the Container
193 |
194 | ---
195 |
196 | # Containers make you app portable
197 |
198 | - It looks the same everywhere
199 | - No matter where you run it
200 | - Doesn't need you to install all the app dependencies on your host
201 |
202 | ---
203 |
204 | # Docker is one container standard
205 |
206 | 
207 |
208 | ---
209 |
210 | # Docker has built a large ecosystem around it
211 |
212 | ---
213 |
214 | # Docker facts
215 |
216 | Launched in March 2013
217 |
218 | Over 100 million downloads
219 |
220 | Over 75 000 Dockerized applications
221 |
222 | 150+ Meetup Groups around the world
223 |
224 | 100+ case studies from companies such as eBay, Rackspace, New Relic, Gilt, Spotify, Cloudflare, Yandex, Cambridge Healthcare, Yelp and RelatelQ.
225 |
226 | ---
227 |
228 | # Containers make your app shareable
229 |
230 | - The needs of the app is defined in a textfile
231 | - A "Dockerfile":
232 | ```
233 | FROM ubuntu:14.04
234 | RUN apt-get install -y redis-server
235 | EXPOSE 6379
236 | ENTRYPOINT ["/usr/bin/redis-server"]
237 | ```
238 |
239 | ---
240 |
241 | # Containers contain everything your app needs
242 |
243 | - Binaries
244 | - Libraries
245 | - File system
246 |
247 | ---
248 |
249 | # Containers use the host for certain things
250 |
251 | - Networking
252 | - Kernel
253 |
254 | ---
255 |
256 | # So no need to run an entire OS (like in a VM) to run an app
257 |
258 | ---
259 |
260 | # Summary
261 |
262 | ---
263 |
264 | # Containers are awesome
265 |
266 | You can use them for your next app
267 |
268 | You can use thousands of already existing apps
269 |
270 | They will always look the same
271 |
272 | They are always portable
273 |
274 | And they leave your host OS clean
275 |
276 | ---
277 |
278 | # Further reading
279 |
280 | [Docker](http://docker.com)
281 |
--------------------------------------------------------------------------------
/accreditation/git/README.md:
--------------------------------------------------------------------------------
1 | Topic:
2 |
3 | Slides for the EMC 2015 Q4 Accreditation Training on: git
4 |
5 | How To Use:
6 |
7 | Method 1: (for offline use, development or maintaining pretty graphics)
8 | * Clone the repo
9 | * Run a local web server (`python -m SimpleHTTPServer 8000` or `python3 -m http.server`)
10 | * Access that server: [Click!](http://localhost:8000)
11 |
12 | Method 2: (for super quick use)
13 | * [Click Here](https://gnab.github.io/remark/remarkise?url=https%3A%2F%2Fraw.githubusercontent.com%2Femccode%2Ftraining%2Faccred-q4%2Faccreditation%2Fgit%2Fgit.md#1)
14 |
--------------------------------------------------------------------------------
/accreditation/git/git.md:
--------------------------------------------------------------------------------
1 | class: center, middle
2 |
3 | # Q4 Accreditation Training
4 | ## Source Code Control with `Git`
5 |
6 | matt cowger (@mcowger) &
7 | jonas rosland (@jonasrosland)
8 |
9 | ---
10 |
11 | # What You'll Learn
12 |
13 | * Why use version control
14 | * How to use Git
15 | * How to use GitHub
16 | * What a pull request is
17 | * Branches and why they're really smart
18 |
19 | ---
20 |
21 | # Why use version control
22 |
23 | * Version control records changes that are made so you can recall specific version later
24 | * Makes it possible for you to work on a feature/bug fix/release without changing production code
25 | * No more "file-version3.py" or "config-020315.conf"!
26 | * Since everything is pure text it's easy to "merge" new code into existing
27 |
28 | ---
29 |
30 | # Git
31 |
32 | * A distributed version control system, where every user has a complete and full copy of the source code.
33 | * If you can't check it in, you can't keep track of it, so you can't version it, so you can't automate it.
34 | * *Everything* belongs in source code control, and git is the standard in open source & cloud native.
35 | * Other possible options: subversion (`svn`), mercurial (`hg`), Perforce (`p4`), ClearCase (`cc`).
36 |
37 | ---
38 |
39 | # GitHub
40 |
41 | * A freemium service to host Git repositories (repos). Public repos are free, private ones are still cheap.
42 | * Most open source projects are hosted and collaborated on here.
43 |
44 | > If you're not on GitHub you don't exist.
45 |
46 | -- Friendly developer
47 |
48 | ---
49 |
50 |
51 | # How does it work?
52 |
53 | 1. Initialize a repository
54 | 2. Clone the repo
55 | 3. Make changes
56 | 4. Commit changes
57 | 5. Push those changes to the repo
58 | 6. ...
59 | 7. Profit!
60 |
61 | ---
62 |
63 | # Create a new repo
64 |
65 | 
66 |
67 |
68 | ---
69 |
70 | # Clone the repo
71 |
72 | ```
73 | git clone https://github.com/jonasrosland/training-repo.git
74 | ```
75 |
76 | ---
77 |
78 | # Make changes
79 |
80 | ```
81 | cd training-repo
82 | echo "Hello World" > yourname.txt
83 | ```
84 |
85 |
86 | ---
87 |
88 |
89 | # Commit changes
90 |
91 | ```
92 | git add yourname.txt
93 | git commit -m "added yourname.txt to the repo"
94 | ```
95 |
96 |
97 | ---
98 |
99 |
100 | # Push changes
101 |
102 |
103 | ```
104 | git push
105 | ```
106 |
107 |
108 | ---
109 |
110 |
111 | # What happened?
112 |
113 | and why?
114 |
115 | ---
116 |
117 |
118 | # DENIED!
119 |
120 | You're not allowed to push to this repo
121 |
122 | --
123 |
124 | So how can we collaborate?
125 |
126 | Fork it!
127 |
128 |
129 | ---
130 |
131 |
132 | # Fork a repo
133 |
134 | 
135 |
136 |
137 | ---
138 |
139 |
140 | # Clone _that_ repo instead of the original one
141 |
142 | ```
143 | git clone https://github.com//training-repo
144 | ```
145 |
146 | Repeat your changes, and try to push
147 |
148 | What happens?
149 |
150 |
151 | ---
152 |
153 |
154 | # Compare to the original
155 |
156 | 
157 |
158 |
159 | ---
160 |
161 |
162 | 
163 |
164 |
165 |
166 | ---
167 |
168 |
169 | # Create a pull request
170 |
171 | 
172 |
173 |
174 | ---
175 |
176 |
177 | 
178 |
179 |
180 | ---
181 |
182 |
183 | ## If a Pull Request is alright, it can then be merged
184 |
185 |
186 | ---
187 |
188 |
189 | 
190 |
191 |
192 | ---
193 |
194 |
195 | 
196 |
197 |
198 | ---
199 |
200 |
201 | # Branches
202 |
203 |
204 | ---
205 |
206 |
207 | # Why use a branch?
208 |
209 | Create a branch for every new feature or bugfix
210 |
211 | Keeps the "master" clean and with only working code
212 |
213 | You can then pull in fixes and features to the master when they're complete
214 |
215 | And then create new releases such as v1.1 or v20150215 from master
216 |
217 |
218 | ---
219 |
220 |
221 | A great cheat sheet:
222 |
223 | http://www.clearvision-cm.com/wp-content/uploads/2014/08/Git-Cheat-Sheet_Clearvision.pdf
224 |
--------------------------------------------------------------------------------
/accreditation/git/images/github_compare.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/accreditation/git/images/github_compare.png
--------------------------------------------------------------------------------
/accreditation/git/images/github_compare2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/accreditation/git/images/github_compare2.png
--------------------------------------------------------------------------------
/accreditation/git/images/github_create_pr.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/accreditation/git/images/github_create_pr.png
--------------------------------------------------------------------------------
/accreditation/git/images/github_merge.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/accreditation/git/images/github_merge.png
--------------------------------------------------------------------------------
/accreditation/git/images/github_merge_successful.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/accreditation/git/images/github_merge_successful.png
--------------------------------------------------------------------------------
/accreditation/git/images/github_new_branch.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/accreditation/git/images/github_new_branch.png
--------------------------------------------------------------------------------
/accreditation/git/images/github_pr.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/accreditation/git/images/github_pr.png
--------------------------------------------------------------------------------
/accreditation/git/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Slideshow
5 |
6 |
7 |
8 |
9 |
10 |
11 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/accreditation/images/Kubernetes overview.001.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/accreditation/images/Kubernetes overview.001.png
--------------------------------------------------------------------------------
/accreditation/images/Kubernetes overview.002.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/accreditation/images/Kubernetes overview.002.png
--------------------------------------------------------------------------------
/accreditation/images/Kubernetes overview.003.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/accreditation/images/Kubernetes overview.003.png
--------------------------------------------------------------------------------
/accreditation/images/Kubernetes overview.004.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/accreditation/images/Kubernetes overview.004.png
--------------------------------------------------------------------------------
/accreditation/images/kubernetes-graph-01.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/accreditation/images/kubernetes-graph-01.png
--------------------------------------------------------------------------------
/accreditation/images/kubernetes-install.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/accreditation/images/kubernetes-install.png
--------------------------------------------------------------------------------
/accreditation/images/mesos.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/accreditation/images/mesos.png
--------------------------------------------------------------------------------
/accreditation/images/open-source-companies.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/accreditation/images/open-source-companies.png
--------------------------------------------------------------------------------
/accreditation/images/rexray-advanced.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/accreditation/images/rexray-advanced.png
--------------------------------------------------------------------------------
/accreditation/images/rexray-basic.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/accreditation/images/rexray-basic.png
--------------------------------------------------------------------------------
/accreditation/images/rexray-logo.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/accreditation/images/rexray-logo.jpg
--------------------------------------------------------------------------------
/accreditation/images/vagrant-windows.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/accreditation/images/vagrant-windows.png
--------------------------------------------------------------------------------
/accreditation/images/what-is-infra.001.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/accreditation/images/what-is-infra.001.png
--------------------------------------------------------------------------------
/accreditation/images/what-is-infra.002.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/accreditation/images/what-is-infra.002.png
--------------------------------------------------------------------------------
/accreditation/images/what-is-infra.003.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/accreditation/images/what-is-infra.003.png
--------------------------------------------------------------------------------
/accreditation/infrastructure-as-code.md:
--------------------------------------------------------------------------------
1 | # Infrastructure As Code
2 | ## 2015 Q2 EMC Accreditation
3 | ## Jonas Rosland & Matt Cowger
4 |
5 | ---
6 |
7 | # What do we define as infrastructure?
8 |
9 | ---
10 |
11 | 
12 |
13 | ^ storage network compute
14 | ^ what we normally sell
15 |
16 | ---
17 |
18 | 
19 |
20 | ^ support services
21 |
22 | ---
23 |
24 | 
25 |
26 | ^ app code, queueing, databases, etc
27 |
28 | ---
29 |
30 | # Why define infrastructure as code?
31 |
32 | - Deploy, monitor and connect together all the pieces needed to run services for the organization
33 | - Processes and tools for faster end-to-end delivery of quality services
34 | - Automation comes built-in
35 |
36 | ---
37 |
38 | # How do we do this?
39 |
40 | - Desired state specified in text files
41 | - Autonomic (self-corrects to desired state)
42 | - State should be known through monitoring
43 | - Remove snowflake servers
44 |
45 | ---
46 |
47 | # Why store them in text files?
48 |
49 | - Easy to read and edit
50 | - Shareable
51 | - Can use standard version control like Git or SVN
52 | - Becomes executable documentation
53 |
54 | ---
55 |
56 | # Simple example
57 |
58 | ```
59 | node 'www2' {
60 | class { 'apache': } # use apache module
61 | apache::vhost { 'awesomewebsite.com': # define vhost resource
62 | port => '80',
63 | docroot => '/var/www/html'
64 | }
65 | }
66 | ```
67 |
68 | ---
69 |
70 | # Change root password
71 |
72 | ```
73 | user { root:
74 | ensure => present,
75 | password => '$ecretP@ssw0rd',
76 | }
77 | ```
78 |
79 | ---
80 |
81 | 
82 |
83 | ---
84 |
85 | 
86 |
87 | ---
88 |
89 | > Manually configured environments are like a house of cards in a china shop
90 | -- Neal Ford
91 |
92 | ---
93 |
94 | # Snowflake servers
95 |
96 | Deploying, provisioning and scaling automatically is virtually impossible if every server is unique
97 |
98 | Adds friction between the requestor and the deployer
99 |
100 | Mistakes happen
101 |
102 | We're all human
103 |
104 | ---
105 |
106 | # What can happen if you don't treat infrastructure as code?
107 |
108 | ---
109 |
110 | # Some firms have found that up to 60% of failures are caused by human error, not hardware failure
111 |
112 | ---
113 |
114 | # Example - Knight Capital Group
115 |
116 | 
117 |
118 | ---
119 |
120 | # Knight Capital Group - What happened?
121 |
122 | Manual deployment of new trading software
123 |
124 | 7 of 8 servers correctly updated
125 |
126 | ## Old function still alive on the 8th server led to
127 | # $440 million loss in 45 minutes
128 |
129 | ---
130 |
131 | # **Treat your infrastructure as code**
132 |
133 | ---
134 |
135 | # Benefits
136 |
137 | Self documenting infrastructure
138 |
139 | You now have source code for how anything in your datacenter is setup
140 |
141 | **Executable documentation**
142 |
143 | ---
144 |
145 | Further reading:
146 |
147 | [PuppetLabs](http://puppetlabs.com)
148 |
149 | [Vagrant](http://vagrantup.com)
150 |
151 | [Docker](http://docker.com)
152 |
153 | [Infrastructure as Code: A reason to smile](http://www.thoughtworks.com/insights/blog/infrastructure-code-reason-smile)
154 |
--------------------------------------------------------------------------------
/accreditation/intro-to-nosql.md:
--------------------------------------------------------------------------------
1 | # NoSQL
2 | ### 2015 Q4 EMC Accreditation
3 | ### Jonas Rosland (@jonasrosland) &
4 | ### Matt Cowger (@mcowger)
5 |
6 | ---
7 |
8 | # "Not Only" SQL
9 |
10 | ---
11 |
12 | # Why Not?
13 |
14 | ---
15 |
16 | * RDBMS Can Do Everything, Right?
17 | * Transactions, performance...
18 | * Not Quite
19 |
20 | ---
21 |
22 | RDBMs Are Good At:
23 |
24 | * SQL (common interface)
25 | * Industry Support
26 | * Small Scale
27 |
28 | ---
29 |
30 | RDBMs Are Bad At:
31 | * Simpler Notation
32 | * Ultra Low Latency
33 | * Large Scale (>10 nodes)
34 | * Changes (schema, etc) on the fly
35 |
36 |
37 | ---
38 |
39 | #Lets Use the Right Tool for the Right Job
40 |
41 | ---
42 |
43 | NoSQL Are Good At:
44 |
45 | * Simple Notation / Access
46 | * Low Latency
47 | * Large Scale
48 | * Changes
49 | * With great power comes great responsibility
50 |
51 | 
52 |
53 | ---
54 |
55 | NoSQL (Might Be) Bad At:
56 |
57 | * Transactional Consistency
58 | * SQL (JOINs, etc)
59 | * Off the Shelf Application Support
60 |
61 | ---
62 |
63 | # Examples of SQL:
64 |
65 | * Oracle
66 | * MySQL
67 | * careful!
68 | * Postgres
69 | * MSSQL Server
70 |
71 |
72 | ---
73 |
74 | # CAP Theorem
75 |
76 | 
77 |
78 | ---
79 |
80 | #4 Common Types
81 |
82 | ---
83 |
84 | #Key Value
85 |
86 | * Stores a simple value (10,456,345) in a 'key': ("usercount")
87 | * Simple 'CRUD' semantics
88 | * Create, Read, Update, Delete
89 | * No schema at all, generally
90 | * Stunningly Scalable (hundreds->thousands of nodes)
91 | * "Get me the current MacOS user count"
92 | * XtremSF cards
93 |
94 | ---
95 |
96 | * Examples:
97 | * Redis (http://try.redis.io/)
98 | * Memcached
99 | * Aerospike
100 | * Cassandra
101 | * Basho Riak
102 | * LevelDB
103 | * Couchbase
104 |
105 | ---
106 |
107 | # Document Stores
108 |
109 | * Store Larger Scale Documents
110 | * Usually in standard encoding: `JSON`, `YML`, `BSON`
111 | * *not* Word documents
112 |
113 | ---
114 |
115 | ```javascript
116 | {
117 | "id": 1,
118 | "name": "A green door",
119 | "price": 12.50,
120 | "tags": ["home", "green"]
121 | }
122 |
123 | ```
124 |
125 | ---
126 |
127 | * Retrieve Documents Based on Key *or* Contents
128 | * Highly Scalable (tens to hundreds of nodes)
129 | * "Show me documents that talk about MacOS"
130 | * ScaleIO
131 |
132 | ---
133 |
134 | * Examples:
135 | * CouchDB / Cloudant (try it for free: https://cloudant.com/sign-up/)
136 | * MarkLogic (popular in .gov)
137 | * MongoDB (try it for free: https://mongolab.com/)
138 | * Amazon SimpleDB (outdated)
139 | * BaseX
140 |
141 | ---
142 |
143 | # Graph Database
144 |
145 | * Represents connections between objects (nodes):
146 | * For instance, if "Wikipedia" were one of the nodes, one might have it tied to properties such as "website", "reference material", or "word that starts with the letter 'w'"
147 | * For associating simple data types, these tend to be orders of magnitude faster than SQL
148 | * "Show me everyone that likes MacOS"
149 | * Rough Scene :)
150 |
151 | ^ Twitter finding friends
152 | ^ Logistics shortest route
153 |
154 | ---
155 |
156 |
157 | 
158 |
159 | * Examples:
160 | * Neo4j (http://console.neo4j.org/)
161 | * InfiniteGraph
162 | * AllegroGraph
163 | * BlazeGraph (used in ViPR SRM)
164 |
165 | ---
166 |
167 | # (Wide) Column Store
168 |
169 | * Uses tables, rows, columns, but does not fix schema like SQL (because its focused on storing the columns, not the rows)
170 | * Great for computing aggregates of huge amounts of data (common in Big Data, data warehouse)
171 | * "Show me everyone that clicked this link between yesterday and today, sorted by age"
172 | * Where total clicks is tens of millions
173 | * Isilon, ScaleIO, DCA
174 |
175 | ---
176 |
177 | * Examples:
178 | * HBase (Hadoop)
179 | * Greenplum
180 | * Vertica
181 | * Teradata
182 | * Amazon Redshift (https://aws.amazon.com/redshift/)
183 | * Google BigQuery
184 |
185 |
186 | ---
187 |
188 | #Conclusions
189 |
190 | * Lots of different options
191 | * Let your data dictate management method
192 | * SQL is not always the right choice
193 | * Try them!
194 |
--------------------------------------------------------------------------------
/accreditation/introduction-to-ci.md:
--------------------------------------------------------------------------------
1 | autoscale: true
2 | # Introduction to Continuous Integration
3 | ### 2015 Q4 EMC Accreditation
4 | ### Jonas Rosland (@jonasrosland) &
5 | ### Matt Cowger (@mcowger)
6 |
7 |
8 | ---
9 |
10 | ## The Problem:
11 |
12 | * Rapid Change -> Rapid Business Value
13 |
14 | but...
15 |
16 | * Rapid Change -> Lack of Confidence (maybe)
17 |
18 | ---
19 |
20 | 
21 |
22 | ---
23 |
24 | 
25 |
26 | ---
27 |
28 | ## How is this solved traditionally?
29 |
30 | * Intermittent 'Integration'
31 | * Slow release train
32 | * Manual QA Testing
33 | * Manual Performance Testing
34 | * 'Release Meetings'
35 |
36 | 
37 |
38 | ---
39 |
40 | ## How do we solve this *now*?
41 |
42 | ---
43 |
44 | #Continous Integration
45 |
46 | ---
47 |
48 | ## The Flow
49 |
50 | ---
51 |
52 | #Stage 1
53 |
54 |
55 | * Developer makes changes locally, tests locally
56 | * Developer runs local unit tests
57 | * (optional) Developer runs manual integration tests using CI system
58 |
59 | ---
60 |
61 | #Stage 2
62 |
63 | * Developer checks in the code (`git`, `subversion`)
64 | * CI system begins testing
65 | * Spins up resources required for test (VMs, containers, etc)
66 | * Checks out code revision added by developer
67 | * Runs series of full tests against database, other services, etc, as needed.
68 |
69 | ---
70 |
71 | #Stage 3
72 |
73 | * Results of test returned to developer (usually 10-60 minutes)
74 | * Checkin either rejected (failed test) or accepted (passed test)
75 |
76 | ---
77 |
78 | > this is a change in mindset first - tools second.
79 |
80 | ---
81 |
82 | # The Tools
83 |
84 | * Jenkins (http://jenkins-ci.org/) (opensource)
85 | * ConcourseCI (http://concourse.ci) (OSS, from CloudFoundry)
86 | * TeamCity (https://www.jetbrains.com/teamcity/)
87 | * Travis (https://travis-ci.org/) (hosted)
88 | * Codeship (https://codeship.com/) (hosted)
89 | * Shipptable (http://www.shippable.com/) (hosted)
90 | * CruiseControl (http://cruisecontrol.sourceforge.net/)
91 | * CircleCI (https://circleci.com/features) (hosted)
92 |
93 | ---
94 |
95 | # A Look at Travis
--------------------------------------------------------------------------------
/accreditation/microservices-and-service-discovery.md:
--------------------------------------------------------------------------------
1 | # Microservices & Service Discovery
2 | ### 2016 Q1 EMC Accreditation
3 | ### Jonas Rosland (@jonasrosland) &
4 | ### Matt Cowger (@mcowger)
5 |
6 | ---
7 |
8 | _The microservices architectural style is an approach to developing a single application as a suite of small services, each running it's own process and communicating with lightweight mechanisms_
9 | - Martin Fowler
10 |
11 | ---
12 |
13 | # Monolithic app vs Microservices
14 |
15 | ---
16 |
17 | # Enterprise application
18 |
19 | - Often built using three parts
20 | - User interface
21 | - Database
22 | - Server-side application
23 |
24 | - The server-side app will handle user requests, execute logic, retrieve and update data and show it to the user
25 |
26 | The server-side app is what we call a **monolith**
27 |
28 | ---
29 |
30 | # Monolithic != bad
31 |
32 | A lot of successful applications have been and are still written as monoliths
33 |
34 | But some apps are in need of faster change cycles, and that's usually were it breaks down
35 |
36 | A small change made to a part of the application usually requires the entire monolith to be rebuilt and redeployed
37 |
38 | Scaling the app requires running multiple copies of the entire application, which might not be the best idea or even possible
39 |
40 | ---
41 |
42 | # Let's look at an example
43 |
44 | ---
45 |
46 | # Monolithic application
47 |
48 | 
49 |
50 | ---
51 |
52 | # Scaling a monolithic application
53 |
54 | 
55 |
56 | ---
57 |
58 | # Move to a microservices architecture
59 |
60 | 
61 |
62 | ---
63 |
64 | # It's not just about scale, but also separation of concern
65 |
66 | ---
67 |
68 | # Traditional organization layout
69 |
70 | 
71 |
72 | ---
73 |
74 | # Business capability organization layout
75 |
76 | 
77 |
78 | ---
79 |
80 | # This also leads to new stacks
81 |
82 | - Developers can use the right tool for the job and are not necessarily locked into one tool or language
83 | - New processes are explored and applied
84 | - Innovation can happen quicker
85 | - New deployments can be done daily or weekly instead of taking months
86 |
87 | ---
88 |
89 | # So how do we keep track of all the microservices?
90 |
91 | ---
92 |
93 | # Service Discovery!
94 |
95 | ---
96 |
97 | 
98 |
99 | ---
100 |
101 | # What are some Service Discovery tools?
102 |
103 | - etcd, by CoreOS
104 | - Consul, by Hashicorp
105 | - Zookeeper, by Apache
106 | - SkyDNS (built on top of etcd)
107 | - Eureka, by Netflix
108 | - Smartstack, by AirBnB
109 | - All of them open source!
110 |
111 | ---
112 |
113 | # Learn more
114 |
115 | - [DigitalOcean tutorial](https://www.digitalocean.com/community/tutorials/the-docker-ecosystem-an-introduction-to-common-components)
116 | - [Microservices by Martin Fowler](http://martinfowler.com/articles/microservices.html)
117 | - [Scaling your app with message oriented decoupled architecture by Cantina](http://cantina.co/scaling-your-app-with-message-oriented-decoupled-architecture/)
118 |
--------------------------------------------------------------------------------
/accreditation/modern-devops-style-communication-and-collaboration-tools.md:
--------------------------------------------------------------------------------
1 | # Modern DevOps-style communication and collaboration tools
2 | ## 2015 Q2 EMC Accreditation
3 | ## Jonas Rosland & Matt Cowger
4 |
5 | ---
6 |
7 | # You're not as efficient as you could be, period
8 |
9 | ---
10 |
11 | ## Your customers are using more modern tools than the old standbys of SharePoint and email
12 |
13 | ---
14 |
15 | # So why wouldn't you?
16 |
17 | ---
18 |
19 | # Let's start with email
20 |
21 | Multitasking with email may seem like it's productive but it's mostly distracting
22 |
23 | Email takes up around 28% of the average desk worker’s day
24 |
25 | It's been estimated to take up to an average of 23 minutes to get back to the task at hand
26 |
27 | Sometimes you forget to answer an email and it will frustrate the sender
28 |
29 | 
30 |
31 | ---
32 |
33 | # The dreaded
34 | # Reply-All...
35 |
36 | ---
37 |
38 | # Phone calls
39 |
40 | Can sometimes be very distracting, both to you and the people around you
41 |
42 | 1-to-1 communication is great for certain things, but useless for team communication
43 |
44 | 
45 |
46 | ---
47 |
48 | # Modern tools
49 |
50 | Modern tools are allowing for semi-synchronous communication and collaboration
51 |
52 | Across regions and timezones
53 |
54 | Answering something in a chat is faster than an email
55 |
56 | Visualizing tasks are better than having them in an out-of-date spreadsheet
57 |
58 | 
59 |
60 | ---
61 |
62 | # Examples
63 |
64 | ---
65 |
66 | # Slack
67 |
68 | A great communication tool with powerful features
69 |
70 | Everything in one place, instantly searchable, available wherever you go
71 |
72 | Makes team and organization communication visible and more productive
73 |
74 | Makes on-boarding easy since new members of a team can see all the previous discussions
75 |
76 | 
77 |
78 | ---
79 |
80 | # HipChat
81 |
82 | Group and private chat with many integrations
83 |
84 | Has built in video calling, screen sharing and are more focused on enterprise
85 |
86 | Available on all platforms, work from anywhere
87 |
88 | 
89 |
90 | ---
91 |
92 | # Trello
93 |
94 | A digital *kanban* board
95 |
96 | Able to visualize tasks
97 |
98 | No longer stuck with crusty old spreadsheets
99 |
100 | 
101 |
102 | ---
103 |
104 | # Integrations and automation
105 |
106 | ---
107 |
108 | # IFTTT
109 | ## If This Then That
110 |
111 | Makes your personal life easier with great integrations to things like Dropbox, RSS Feeds, Facebook and many more
112 |
113 | Something happens in one place and jumpstarts a workflow to another thing
114 |
115 | Example: You're tagged in a picture on Facebook, automatically store that picture in Dropbox
116 |
117 | 
118 |
119 | ---
120 |
121 | # Zapier
122 |
123 | Professional integration and automation tool
124 |
125 | Similar to IFTTT but for professional applications such as Slack, Basecamp, Trello, Evernote, OneDrive, etc
126 |
127 | 
128 |
129 | ---
130 |
131 | # ChatOps
132 |
133 | ---
134 |
135 | # Team collaboration in chat rooms
136 |
137 | Team members type commands into a chat room, a chat bot then executes those commands
138 |
139 | Commands can range from deployments to security event responses to team notifications
140 |
141 | The entire team collaborates in real-time
142 |
143 | 
144 |
145 | ---
146 |
147 | # Summary
148 |
149 | Use more efficient tools
150 |
151 | For both personal and professional tasks
152 |
153 | Don't use email
154 |
155 | ---
156 |
157 | Further reading
158 |
159 | [Slack](http://slack.com)
160 | [HipChat](http://hipchat.com)
161 | [Trello](http://trello.com)
162 | [IFTTT](http://ifttt.com)
163 | [Zapier](http://zapier.com)
164 |
--------------------------------------------------------------------------------
/accreditation/object-storage/README.md:
--------------------------------------------------------------------------------
1 | Topic:
2 |
3 | Slides for the EMC 2015 Q4 Accreditation Training on: object storage
4 |
5 | How To Use:
6 |
7 | Method 1: (for offline use, development or maintaining pretty graphics)
8 | * Clone the repo
9 | * Run a local web server (`python -m SimpleHTTPServer 8000` or `python3 -m http.server`)
10 | * Access that server: [Click!](http://localhost:8000)
11 |
12 | Method 2: (for super quick use)
13 | * [Click Here](https://gnab.github.io/remark/remarkise?url=https%3A%2F%2Fraw.githubusercontent.com%2Femccode%2Ftraining%2Faccred-q4%2Faccreditation%2Fobject-storage%2Fobject-storage.md#1)
14 |
--------------------------------------------------------------------------------
/accreditation/object-storage/images/block.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/accreditation/object-storage/images/block.png
--------------------------------------------------------------------------------
/accreditation/object-storage/images/object.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/accreditation/object-storage/images/object.png
--------------------------------------------------------------------------------
/accreditation/object-storage/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Slideshow
5 |
6 |
7 |
8 |
9 |
10 |
11 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/accreditation/object-storage/object-storage.md:
--------------------------------------------------------------------------------
1 | class: center, middle
2 |
3 | # Q1 Accreditation Training
4 | ## Object Storage Basics
5 |
6 | matt cowger (@mcowger) &
7 | jonas rosland (@jonasrosland)
8 |
9 | ---
10 |
11 | # What You'll Learn
12 |
13 | * What is object storage
14 | * How do we use it differently
15 | * Why are people using more
16 | * What are the access methods
17 | * How can EMC help
18 |
19 | ---
20 |
21 | # What Is Object Storage?
22 |
23 | ###Traditional Concepts:
24 |
25 | * Block
26 | * File (possibly on top of block)
27 | * Tape
28 |
29 | ---
30 |
31 | ## Block
32 |
33 | * Accessed via logical block address
34 | * Random access anywhere in the device
35 | * Low latency - transaction focused
36 | * 512 / 4K block sizes
37 | * Difficult to share across systems
38 | * Difficult to replicate efficiently
39 |
40 | 
41 |
42 |
43 | ---
44 |
45 | ## File
46 |
47 | * Accessed via filename
48 | * Random access anywhere in the file
49 | * Moderate latency
50 | * File sizes 2GB-~2PB
51 | * Difficult to share across systems (NFS doesn't count)
52 | * Still focused on transactions
53 |
54 | ---
55 |
56 | ## Tape
57 |
58 | * Accessed by 'ID' on tape.
59 | * Linear access only
60 | * Very high latency (think minutes)
61 | * Tough to share
62 | * Focused on $/GB
63 |
64 | ---
65 |
66 | # A 4th Idea - Object Storage
67 |
68 | Something that has:
69 |
70 | * low $/GB (not quite as low as tape)
71 | * Easy to share across thousands of systems
72 | * Easy to replicate - eventually consistent
73 | * Accessed by HTTP (modern)
74 | * Objects (of any reasonable size) are the unit of access, not blocks or segments
75 | * Rich metadata
76 | * Response time in hundreds of milliseconds to seconds
77 |
78 | ---
79 |
80 | 
81 |
82 | ---
83 |
84 | # EMC's Story
85 |
86 | * FilePool -> EMC Centerra
87 | * Atmos
88 | * Isilon
89 | * ECS / ViPR Object
90 |
91 | ---
92 |
93 | # Other Common Implementations
94 |
95 | * Amazon S3
96 | * Rackspace Files
97 | * Google Cloud Storage
98 | * Scality
99 | * Ceph
100 |
101 | ---
102 |
103 | # Where Is It Used?
104 |
105 | * Cloud scale storage of:
106 | * Images & Videos
107 | * Audio
108 | * Documents
109 | * Large Datasets
110 |
111 | ---
112 |
113 | ### How Do I Access It
114 |
115 | As a user, transparently via HTTP links (this comes from S3)
116 |
117 | 
118 |
119 | ---
120 |
121 | As a developer, using HTTP and various SDKs:
122 |
123 | ```bash
124 | curl -X PUT -T "${file}" \
125 | -H "Host: ${bucket}.s3.amazonaws.com" \
126 | -H "Date: ${dateValue}" \
127 | -H "Content-Type: ${contentType}" \
128 | -H "Authorization: AWS ${s3Key}:${signature}" \
129 | https://${bucket}.s3.amazonaws.com/${file}
130 | ```
131 |
132 | ```python
133 | import tinys3
134 | conn = tinys3.Connection(KEY,SECRET,tls=True)
135 | f = open('some_file.zip','rb')
136 | conn.upload('some_file.zip',f,'my_bucket')
137 | ```
138 |
139 | ---
140 |
141 | #Benefits
142 |
143 | * Techniques like SATA drives and erasure coding make it VERY efficient in $/GB ($0.02/GB)
144 | * Native HTTP management and access make it very easy to develop for and access with any language / framework
145 | * Lack of hard consistency makes it easy to replicate across long distances.
146 |
147 | ---
148 |
149 | # In Combination:
150 |
151 | Along with cloud native platforms like Cloud Foundry, object storage is commonly used with:
152 |
153 | * A modern language like Python or Node.JS
154 | * A NoSQL database for managing user metadata
155 | * A object store for managing large scale user data (uploaded images, music, etc)
156 |
157 | ---
158 |
159 | #Keywords
160 |
161 | If your customer is thinking about:
162 |
163 | * Cloud Native applications
164 | * Large scale image repositories (including healthcare)
165 | * Hadoop data
166 | * Archive storage
167 |
168 | talk to your local object storage specialist
--------------------------------------------------------------------------------
/accreditation/open-source-is-good-for-business-and-humanity.md:
--------------------------------------------------------------------------------
1 | #Open Source is good for business and humanity
2 |
3 | ## 2016 Q2 EMC Accreditation
4 |
5 | ### Jonas Rosland (@jonasrosland) &
6 | ### Matt Cowger (@mcowger)
7 | #### Research by Kenny Coleman
8 | ---
9 |
10 | # History of Open Source
11 |
12 | ---
13 | 
14 | ## The UNIVAC A-2 system was released in 1953 to customers with its source code
15 |
16 | ^ developed at the UNIVAC division of Remington Rand in 1953, was released to customers with its source code. They were invited to send their improvements back to UNIVAC. Thus it is believed that A-2 was the first example of free and open-source software.
17 |
18 | ^ As large-scale operating systems matured, fewer organizations allowed modifications to the operating software, and eventually such operating systems were closed to modification. However, utilities and other added-function applications are still shared and new organizations have been formed to promote the sharing of software.
19 |
20 | ---
21 |
22 | 
23 |
24 | ## In the early 1970s AT&T distributed early versions of UNIX at no cost to government and academic researchers
25 |
26 | ^ After UNIX became more widespread in the early 1980s, AT&T stopped the free distribution and charged for system patches
27 |
28 | ^ In the early 1970s AT&T distributed versions of UNIX at no cost to government and academic researchers, but these versions did not come with permission to redistribute or to distribute modified versions, and were thus not free software in the modern meaning of the phrase. After UNIX became more widespread in the early 1980s, AT&T stopped the free distribution and charged for system patches. As it is quite difficult to switch to another architecture, most researchers paid for a commercial licence.
29 |
30 | ^ In the late 1970s and early 1980s, computer vendors and software-only companies began routinely charging for software licences, marketing it as "Program Products" and imposing legal restrictions on new software developments, now seen as assets, through copyrights, trademarks, and leasing contracts. In 1979, AT&T began to enforce its licences when the company decided it might profit by selling the Unix system.
31 |
32 |
33 | ---
34 |
35 | 
36 |
37 | ## In 1983, Richard Stallman published the GNU Manifesto and launched the GNU Project
38 |
39 | ^In 1983, Richard Stallman published the GNU Manifesto and launched the GNU Project to write a complete operating system free from constraints on use of its source code. Particular incidents motivated this. One case includes an annoying printer couldn't be fixed because the source code was withheld from users. The GNU Manifesto outlined the GNU project's purpose and explained the importance of free software. Soon after the launch, he coined the term "free software" and founded the Free Software Foundation to promote the concept and a free software definition was published in February 1986
40 |
41 | ---
42 |
43 | 
44 |
45 | ## The Linux kernel, started by Linus Torvalds, was released as freely modifiable source code in 1991
46 |
47 | ^ The Linux kernel, started by Linus Torvalds, was released as freely modifiable source code in 1991. The licence wasn't a free-software licence, but in February 1992, Torvalds relicensed the project under the GNU General Public License. Much like Unix, Torvalds' kernel attracted the attention of volunteer programmers everywhere.
48 |
49 | ^ Until this point, the GNU project's lack of a kernel meant that no complete free-software operating systems existed. The development of the Linux kernel closed that last gap. The combination of these two made the first complete free-software operating system.
50 |
51 | ---
52 |
53 | 
54 |
55 | ## In 1995, The Apache HTTP Server was released
56 |
57 | ---
58 |
59 | 
60 |
61 | ## In 1997, Eric Raymond published The Cathedral and the Bazaar, a reflective analysis of the hacker community and free-software principles
62 |
63 | ^ In 1997, Eric Raymond published The Cathedral and the Bazaar, a reflective analysis of the hacker community and free-software principles. The paper received significant attention in early 1998 and was one factor in motivating Netscape to release their popular Netscape Communicator Internet suite as free software. This code is today the basis for Mozilla Firefox and Thunderbird.
64 |
65 | ^ Netscape's act prompted Raymond and others to look into how to bring free-software principles and benefits to the commercial-software industry. They concluded that FSF's social activism was not appealing to companies like Netscape, and looked for a way to rebrand the free-software movement to emphasize the business potential of the sharing of source code.
66 |
67 | ---
68 |
69 | # Now here's where it gets really interesting
70 |
71 | ---
72 |
73 | 
74 |
75 | ## On January 22, 1998, Netscape announces that they will give away their Navigator browser and it's source code
76 |
77 | ^ http://www.cnet.com/news/netscape-now-for-free/
78 |
79 | ---
80 |
81 | 
82 |
83 | ## The “open source” label was created at a strategy session held on February 3rd, 1998 in Palo Alto, California
84 |
85 | ^ https://opensource.org/history
86 |
87 | ---
88 |
89 | 
90 |
91 | ## Then on February 23rd, Netscape created the Mozilla project to coordinate the development of their now Open Source software
92 |
93 | ---
94 |
95 | # Open Source definition
96 |
97 | - Freely accessed, used, changed and shared
98 | - Open collaboration
99 | - No vendor lock-in
100 | - Can be used for commercial purposes
101 |
102 | ---
103 |
104 | # So how do you start with Open Source?
105 |
106 | ---
107 |
108 | # Open Source checklist
109 |
110 | 1. Have an idea and share it with others
111 | 2. Choose a license
112 | 3. Start work and publish it
113 | 4. Invite the community and grow with it
114 |
115 | ---
116 |
117 | # It's not all just code
118 |
119 | We also need:
120 | - Designers
121 | - Writers
122 | - Marketing
123 | - Community managers
124 | - And much more
125 |
126 | ---
127 |
128 | ## Open Source made it possible
129 |
130 | - The Linux, Apache, MySQL, PHP (LAMP) stack
131 | - OpenSSL
132 | - BIND, the DNS server that powers the Internet
133 | - Android devices
134 | - Arduino and the Internet of Things
135 |
136 | ---
137 |
138 | # Who creates Open Source software?
139 |
140 | ---
141 |
142 | 
143 |
144 | ---
145 |
146 | # Together with and thanks to Open Source we now have
147 |
148 | - Highly available cloud resources
149 | - Cheap computing
150 | - Automation tools
151 | - Short, iterative development cycles
152 | - Massive amounts of ready-to-run code
153 |
154 | ---
155 |
156 | # Enabling you to move fast
157 |
158 | - Industries of: :airplane: - :high_heel: - :dollar: - :car: - :newspaper: - :movie_camera:
159 | - You can start with little to no financial resources
160 | - Global collaboration (acceleration)
161 | - Nothing to hide (bug-fixes, features, security)
162 |
163 | ---
164 |
165 | # To create life-changing opportunities
166 |
167 | - Secure communications world-wide
168 | - Self-driving cars
169 | - Retrieving images from the surface of Mars
170 | - Posting pictures on Facebook
171 |
172 | ---
173 |
174 | # 1953 - now
175 | ## It all started by sharing code
176 | ---
177 |
178 | # Resources:
179 |
180 | - https://en.wikipedia.org/wiki/History_of_free_and_open-source_software
181 | - https://opensource.org/history
182 | - http://www.cnet.com/news/netscape-now-for-free/
183 |
--------------------------------------------------------------------------------
/accreditation/project-rexray-and-modern-data-persistence.md:
--------------------------------------------------------------------------------
1 | # Project REX-Ray and Modern Data Persistence
2 | ### 2016 Q3 EMC Accreditation
3 | ### Jonas Rosland (@jonasrosland)
4 | ### Matt Cowger (@mcowger)
5 |
6 | ---
7 |
8 | # What is REX-Ray?
9 |
10 | - An Open Source project by EMC {code}
11 | - Focused on bringing storage and containers closer together
12 | - A leading storage project in the Docker ecosystem
13 |
14 | 
15 |
16 | ---
17 |
18 | # Problem statement
19 |
20 | - Containers are mostly seen as stateless
21 | - Storing data in them is risky
22 | - Tools to store data in containers are not easy to use
23 |
24 | ---
25 |
26 | # Mission
27 |
28 | - Create a storage management component for Docker
29 | - Be able to handle more than one storage subsystem
30 | - Integrate and follow Docker’s development cycle
31 | - Open Source from the start
32 |
33 | ---
34 |
35 | # How does storage in containers work?
36 |
37 | - When a container starts, we can map storage to it
38 | - For apps such as databases this is a necessity
39 | - When a container stops, the storage is unmounted and can be reused by another container
40 |
41 | ---
42 |
43 | # Why not use local storage?
44 |
45 | - Local storage locks the container’s data to one server
46 | - Using non-local storage gives us the possibility to move containers across servers
47 | - Having that possibility is crucial for HA environments
48 |
49 | ---
50 |
51 | # Result
52 |
53 | - Industry recognition and broad use of REX-Ray
54 | - Focused and ongoing development efforts
55 | - Simple setup for multiple storage environments:
56 | - AWS
57 | - GCE
58 | - OpenStack
59 | - Rackspace
60 | - EMC (ScaleIO, XtremIO, VMAX, Isilon)
61 | - VirtualBox
62 |
63 | ---
64 |
65 | # Basic possibilities
66 |
67 | 
68 |
69 | ---
70 |
71 | # Advanced possibilities
72 |
73 | 
74 |
75 | ---
76 |
77 | # Demo!
78 |
79 | ---
80 |
81 | # REX-Ray benefits
82 |
83 | - Gives you the possibility to use any storage platform, and even multiple platforms at the same time
84 | - Always in sync with Docker’s development cycle
85 | - Integrated with Docker, Mesos, Marathon and Kubernetes
86 |
87 | ---
88 |
89 | # For more information:
90 |
91 | http://rexray.readthedocs.io
92 |
93 | http://blog.emccode.com
94 |
95 | http://emccode.com
96 |
97 | https://github.com/emccode/vagrant
98 |
--------------------------------------------------------------------------------
/accreditation/what-is-cf.md:
--------------------------------------------------------------------------------
1 | #Cloud Foundry
2 |
3 | ## 2015 Q3 EMC Accreditation
4 |
5 | ### Matt Cowger (@mcowger)
6 | ### Jonas Rosland (@jonasrosland)
7 |
8 | ---
9 |
10 | ^ Open this presentation with [Deckset](http://www.decksetapp.com/)
11 | ^ Matt
12 |
13 | ---
14 |
15 | # [fit] Part 1: What's a PaaS?
16 |
17 | ---
18 |
19 | PaaS is a category of cloud computing services that provides a platform allowing customers to develop, run and manage applications without the complexity of building and maintaining the infrastructure typically associated with developing and launching an app.
20 |
21 | ---
22 |
23 |
24 | # CF 101
25 |
26 | >what problems does it solve?
27 |
28 | * managing operating systems sucks.
29 | * managing runtimes sucks
30 | * managing deployment of dependencies sucks
31 | * managing application isolation sucks
32 | * managing deployment tasks sucks
33 |
34 | ---
35 |
36 |
37 | ## Process for deploying/scaling app on EC2 / EHC / etc
38 |
39 | 1. Deploy VM (the easy part - handled by IaaS...CMDB?)
40 | 2. Secure VM (or write some puppet)
41 | 2. Install runtime (with what? rpm? tarball?)
42 | 3. install dependencies (or write some scripts)
43 | 4. Install application (tarball? RPM? git?)
44 | 5. Start application (how? job engine? keep it running?)
45 | 6. Modify load balancer (how?)
46 | 7. Modify firewall (how?)
47 | 8. Add health checks (to where? http? tcp? )
48 |
49 | ---
50 |
51 | ## Process for deploying app on CF
52 |
53 | 1. `cf push app_name`
54 |
55 | ## Process for scaling app on CF
56 |
57 | 1. `cf scale app_name -i instance_count`
58 |
59 | ---
60 |
61 | # [fit] Components
62 |
63 | ---
64 |
65 | * Cloud Controller
66 |
67 | * UAA
68 |
69 | * Diego
70 |
71 | * Loggregator
72 |
73 | * GoRouter
74 |
75 | * Buildpacks
76 |
77 | * Services
78 |
79 | * BOSH
80 |
81 | ---
82 |
83 | # Cloud Controller
84 |
85 | * API layer
86 |
87 | * `cf` cli talks to this
88 |
89 | ```
90 | mcowger@hex:~
91 | $ cf apps
92 | Getting apps in org EVP / space EMC as matt.cowger@emc.com...
93 | OK
94 |
95 | name requested state instances memory disk urls
96 | boisecode stopped 0/1 128M 1G boisecode.cfapps.io
97 | bourbonTweetAlerts started 1/1 256M 1G bourbontweetalerts.cfapps.io
98 | cfworker started 1/1 128M 1G cfworker.cfapps.io
99 | ```
100 |
101 | ---
102 |
103 | # UAA
104 |
105 | * Authentication layer
106 |
107 | * Internal or LDAP Backend
108 |
109 | * OAUTH2 Provider
110 |
111 | * Recent EMC work
112 |
113 | ---
114 |
115 |
116 | # Diego
117 |
118 | * Elastic Runtime Components
119 |
120 | * Container Management (through Garden)
121 | * Container Scheduling
122 | * Droplet Creation
123 | * Placement / Availability Management
124 | * Deployment of Applications
125 |
126 | * Recent rewrite to enable new hotness
127 |
128 | ---
129 |
130 | # Loggregator
131 |
132 | * Platform for delivering application log output
133 |
134 | * Collates as needed
135 |
136 | * `Firehose` too
137 |
138 |
139 | ##Example
140 |
141 | ```
142 | $ cf logs --recent chargers2
143 | 2015-06-02T08:45:42.48-0700 [App/0] OUT chargers2.cfapps.io - [02/06/2015:15:45:42 +0000] "GET / HTTP/1.1" 200 0 8461 ...
144 | 2015-06-02T08:45:45.06-0700 [App/1] OUT chargers2.cfapps.io - [02/06/2015:15:45:45 +0000] "GET / HTTP/1.1" 200 0 8461 ...
145 |
146 | ```
147 |
148 |
149 | ---
150 |
151 | # Gorouter
152 |
153 |
154 | * Accepts requests for a specific 'route' (URL)
155 |
156 | * Passes them to available applications & instances assigned to that route (possibly more than 1)
157 |
158 | * Can be replaced by other load balancers if needed
159 |
160 | ---
161 |
162 | # Buildpacks
163 |
164 | * Provide basis for running application:
165 |
166 | * Language runtime (`Ruby`, `Python`, `COBOL`, `Java`, etc)
167 | * Module installation (as needed)
168 | * Debugger setup (as needed)
169 | * anything language or environment specific
170 |
171 | ---
172 |
173 | # Services
174 |
175 | > no application is an island
176 |
177 | * External tools automatically provisioned & attached
178 |
179 | * Databases (MySQL, Oracle, Postgres)
180 | * NoSQL (Redis, MongoDB, etc)
181 | * Message Queues (0mq, RabbitMQ, etc)
182 |
183 |
184 | ---
185 |
186 | # BOSH
187 |
188 | * Responsible for using the IaaS (vSphere, vCD, OpenStack, AWS, etc) to build virtual machines
189 |
190 | * VMs are called 'cells'
191 |
192 | * CF on Bare Metal is coming :)
193 | * Currently based on Ubuntu
194 | * Support for VMware Photon is planned
195 |
196 | ---
197 |
198 |
199 | # BOSH, cont.
200 |
201 | * Responsible for managing:
202 |
203 | * Long Running Processes (services, apps, parts of itself)
204 | * Tasks (single run requests (deploy X, create Y))
205 | * Upgrades of infrastructure
206 |
--------------------------------------------------------------------------------
/devops-geekweek/12_Factor_Apps_For_Ops.md:
--------------------------------------------------------------------------------
1 | ^ build-lists: true
2 | ^ Open this presentation with [Deckset](http://www.decksetapp.com/)
3 |
4 |
5 | ![fit] (images/title.jpg)
6 |
7 | ---
8 |
9 | ![fit] (images/speakers.jpg)
10 |
11 |
12 | # 12 Factor Apps for Operations
13 |
14 | ### rags srinivas (@ragss)
15 | ### matt cowger (@mcowger)
16 |
17 | ---
18 |
19 | >http://12factor.net
20 |
21 | ---
22 |
23 | > I didn't change anything!
24 | -- every. developer. ever.
25 |
26 | ---
27 |
28 | > Well the environment didn't change!
29 | -- every. ops. person. ever.
30 |
31 | ---
32 |
33 | # \#1: Codebase
34 |
35 | * Everything in revision control
36 | * Including environment configuration
37 |
38 | ^ Matt
39 |
40 | ---
41 |
42 | # Revision Control -> `git blame`
43 | #####(`svn blame` if you must)
44 |
45 | ^ Matt
46 |
47 | ---
48 |
49 | ![fit] (http://memecrunch.com/meme/ZEUJ/if-you-bothered-to-look-at-git-blame/image.jpg)
50 |
51 | ---
52 |
53 | # \#2: Dependencies
54 |
55 | * Dependencies must be explicitly declared
56 | * They should be declared with the rest of the code, and tracked the same way
57 | * Dependencies tracking should contain version numbers of dependencies
58 |
59 | ---
60 |
61 | ![fit] (https://thisistwitchy.files.wordpress.com/2012/11/passing-the-buck.jpg)
62 |
63 | ^Matt - If it wasn't documented, how could you know it even was a requirement? if it doesn't exist in SCM, it doesn't exist.
64 |
65 | ---
66 |
67 | ![fit] (http://net-informations.com/faq/framework/img/obsolete.png)
68 |
69 | ^Matt - Version everything. Deprecated functions means version numbers are critical. Image courtesy: http://blog.simpsn.com/replacing-deprecated-functions-in-phpthumb-to-be-compatible-with-php-version-5-3-0
70 |
71 | ---
72 |
73 | # \#3: Config
74 |
75 | * Config belongs in the environment if possible - it varies between deploys, but the code doesn't
76 | * Includes access credentials, logging config, etc.
77 | * Should be read at runtime, not preprocessed into code.
78 |
79 | ^Matt - config, especially passwords, suck.
80 |
81 | ---
82 |
83 | ![fit] (images/configshuffle.png)
84 |
85 | ^Matt - this is a recipe for horribleness.
86 |
87 | ---
88 |
89 | * Only people with access to host & account can see creds
90 | * Creds can be specific (maybe avoid shared accounts!)
91 | * Now everyone knows the live config, all the time, and be sure code is using it.
92 | * Less danger of having critical file stolen/checked in
93 |
94 | ---
95 |
96 | ![fit] (images/yaml.jpg)
97 |
98 | ---
99 |
100 | # \#4: Backing Services
101 |
102 | * Anything your application uses as a resource (database, queueing system, email, cache) should be referenced with 'bindings' to these services.
103 | * All applications deployed with explicit declarative references ( as in manifest.yml)
104 | * Avoid implicit references (User Provided Services)
105 |
106 | ^Rags - Explicitly declared. Access methods must be declared as well. Put everything in YAML, for example
107 |
108 |
109 | ---
110 |
111 | ![fit] (images/profiles.jpg)
112 |
113 | ---
114 |
115 | # \#5: Build Release Run
116 |
117 | * Build, Release and Run are separate stages for the application life cycle.
118 | * Version everything
119 | * Use profiles
120 | * Blue/Green Deployments are a rule, not an exception.
121 |
122 |
123 | ^Rags - Everything is code. Infrastructure is code. Data is code. If it's manual it's broke. If it's not versioned it's broke. This is related to #3 - config
124 |
125 | ---
126 |
127 | ![fit] (images/bellichick.jpg)
128 |
129 | ^ Image courtesy: pintrest.com
130 |
131 | ---
132 |
133 | # \#6: Processes
134 |
135 | * Seperation of concerns - each microservice is a single process
136 | * Instances of running code to be stateless - certain exceptions apply
137 | * This makes apps more resilient, and easier to recover
138 | * Categorize processes into Stateful and Stateless
139 |
140 | ^Rags - The Unix principle. Stateless - no problem. Treat Stateful processes or services differently.
141 |
142 | ---
143 | # \#7: Port Binding
144 |
145 | * Export services via port binding
146 | * For instance HTTP is exported as a service via port binding and not injected at run time.
147 | * The ultimate goal is to be able to horizontally scale.
148 |
149 |
150 | ^Rags - CF, Lattice and Containers deal with this for the most part. Don't always assume that MySQL runs on 3306 or Couchbase runs on 8091.
151 |
152 | ---
153 |
154 | # \#8: Concurrency
155 |
156 | * An extension of # 6 above.
157 | * An implication to scale out.
158 | * Not necessarily required for certain aspects (single process workers, etc)
159 |
160 | ^Rags -- Application locking and concurrency built in.
161 |
162 | ---
163 |
164 | ![fit] (images/concurrency.png)
165 |
166 | ^ `http://12factor.net/concurrency`
167 |
168 | ---
169 |
170 | # \#9: Disposability
171 |
172 | * Losing a process should be a normal event
173 | * No loss of state for user if we lose a process
174 | * Startup times should be low
175 | * Platforms can adapt to errant processes and self heal if required.
176 |
177 | ^Rags
178 |
179 | ---
180 |
181 | ![fit] (http://upload.wikimedia.org/wikipedia/en/thumb/d/de/Cat-Cute-Kitten-HD-Wallpaper.jpg/1024px-Cat-Cute-Kitten-HD-Wallpaper.jpg)
182 | ![fit] (http://img.photobucket.com/albums/v453/jmr8891/Silkies/Misc/IMG_7264.jpg)
183 |
184 | ^ Image courtesy: http://www.slideshare.net/gmccance/cern-data-centre-evolution
185 |
186 | ---
187 |
188 | ![fit] (images/workedonmine.jpg)
189 |
190 | ---
191 |
192 | # \#10: Dev / Prod Parity
193 |
194 | * Dev MUST == Production in config, but not performance
195 | * Following the above helps do this
196 |
197 | ---
198 |
199 | ![fit] (images/worksonmymachine.png)
200 |
201 |
202 | ---
203 |
204 | # \#11: Logs
205 |
206 | ---
207 |
208 | ![fit] (images/criticalerror.png)
209 |
210 | ---
211 |
212 | * Log *everything*
213 | * Storage is cheap
214 | * Searching is cheap
215 | * Logs help fix problems *after* they happen
216 | * Use tokens for specific flows
217 |
218 |
219 | ---
220 |
221 | ![fit] (images/rca.jpg)
222 |
223 | ---
224 |
225 | # Measure/Monitor Everything
226 |
227 | ---
228 |
229 | ![fit] (images/pcfopsmanager.tiff)
230 |
231 | ---
232 |
233 | # \#12: Admin Processes
234 |
235 | * Use your app/framework for these... build in the tools as needed.
236 | * Don’t run updates directly against a database
237 | * Don’t run them from a local terminal window
238 | * ChatOps can help here
239 |
240 |
241 | ---
242 |
243 | # More Resources
244 |
245 | * [Systems that Never Stop] (http://www.infoq.com/presentations/Systems-that-Never-Stop-Joe-Armstrong)
246 | * [Pivotal Podcasts: Episode 23 (Operational transformation) ](http://blog.pivotal.io/podcasts-pivotal)
247 | * [You Build it, you run it - an interview with Werner Vogels] (https://queue.acm.org/detail.cfm?id=1142065)
248 | * [This presentation] (https://github.com/emccode/training/blob/master/cfsummitpresos/)
249 |
250 |
251 |
252 |
253 |
254 |
255 |
256 |
--------------------------------------------------------------------------------
/devops-geekweek/Day1-Part1-Tools.md:
--------------------------------------------------------------------------------
1 | #DevOps Agile Geek Week
2 |
3 | >Software & Infra do not scale. Software & Infra teams do not scale. Architecture should be as much about enabling small teams to work on small components as the technical requirements of the software.
4 |
5 | ^ Open this presentation with [Deckset](http://www.decksetapp.com/)
6 |
7 | ---
8 |
9 | #What You'll Learn
10 |
11 | * How to 'do' Agile
12 | * How *not* to 'do' Agile
13 | * Agile/DevOps related tools
14 | * IaaS and PaaS basics
15 | * How to talk about this in the real world
16 |
17 | ---
18 |
19 | #Themes
20 |
21 | - Automation
22 | - Text Configuration (JSON/YAML)
23 | - machine parseable, human readable
24 | - Everything in Git
25 | - Local Tools = Production Environments - Scale
26 | - Free/Open Source Tools
27 |
28 | ---
29 |
30 | #Day 1 Agenda
31 |
32 | * Get acclimated to the [tools](Day1-Part1-Tools.md) in use
33 | * Discuss basic Agile methodology and how to use it.
34 | * Do first Sprint Planning for team project, including story pointing.
35 |
36 |
37 | ---
38 |
39 | #Tools
40 |
41 | [Git](https://help.github.com/articles/set-up-git/)
42 | [CloudFoundry CLI](http://docs.cloudfoundry.org/devguide/installcf/)
43 | [Slack](http://slack.com)
44 | [Trello](http://trello.com)
45 |
46 | Optional
47 | - [Vagrant](http://vagrantup.com)
48 | - [VirtualBox](http://virtualbox.org)
49 | - [Boot2Docker](http://boot2docker.io/)
50 |
51 | ---
52 |
53 | #Git
54 |
55 | A distributed version control system, where every user has a complete and full copy of the source code.
56 |
57 | If you can't check it in, you can't keep track of it, so you can't version it, so you can't automate it.
58 |
59 | *Everything* belongs in source code control, and git is the standard in 3rd platform.
60 |
61 | Other possible options: subversion (svn), mercurial (hg), Perforce (p4), ClearCase (cc).
62 |
63 | ---
64 |
65 | ##GitHub?
66 |
67 | A freemium service to host Git repositories (repos). Public repos are free, private ones are still cheap.
68 |
69 | Most open source projects are hosted and collaborated on here.
70 |
71 | > If you're not on GitHub you don't exists.
72 | -- Friendly developer
73 |
74 | ---
75 |
76 | #CloudFoundry CLI
77 |
78 | A command line tool for managing CloudFoundry applications and related services. Again, all CLI so that it can be scripted and automated.
79 |
80 | Simple commands to deploy, scale and monitor applications.
81 |
82 | ---
83 |
84 | #Slack
85 |
86 | Think of it like IRC on 'roids'. Team chat with multiple channels, integrations with services like GitHub, Trello, etc.
87 |
88 | Often used to significantly replace email within Agile teams.
89 |
90 | ---
91 |
92 | #Trello
93 |
94 | An online 'Kanban' board to track tasks and completion.
95 |
96 | Very simple and user friendly, can be used for anything from sprint management to planning a birthday party.
97 |
--------------------------------------------------------------------------------
/devops-geekweek/Day2-Part1-Git.md:
--------------------------------------------------------------------------------
1 | # Source Code Management
2 |
3 | ^ Open this presentation with [Deckset](http://www.decksetapp.com/)
4 | ^ Jonas
5 |
6 | ---
7 |
8 | # What You'll Learn
9 |
10 | * Why use version control
11 | * How to use Git
12 | * How to use GitHub
13 | * What a pull request is
14 | * Branches and why they're really smart
15 |
16 | ---
17 |
18 | # Day 2 Agenda
19 |
20 | * Daily standup
21 | * Basic tutorial on GitHub / Source Code Management
22 | * 12 Factor Apps
23 | * Team works via collaborative methods (Slack, Asana, Google Hangouts, etc) to complete tasks committed for that day.
24 | * Optional: Vagrant & Packer
25 |
26 | ---
27 |
28 | # Why use version control
29 |
30 | - Version control records changes that are made so you can recall specific version later
31 | - Makes it possible for you to work on a feature/bug fix/release without changing production code
32 | - No more "file-version3.py" or "config-020315.conf"!
33 | - Since everything is pure text it's easy to "merge" new code into existing
34 |
35 | ---
36 |
37 | # Git
38 |
39 | A distributed version control system, where every user has a complete and full copy of the source code.
40 |
41 | If you can't check it in, you can't keep track of it, so you can't version it, so you can't automate it.
42 |
43 | *Everything* belongs in source code control, and git is the standard in 3rd platform.
44 |
45 | Other possible options: subversion (svn), mercurial (hg), Perforce (p4), ClearCase (cc).
46 |
47 | ---
48 |
49 | # GitHub
50 |
51 | A freemium service to host Git repositories (repos). Public repos are free, private ones are still cheap.
52 |
53 | Most open source projects are hosted and collaborated on here.
54 |
55 | > If you're not on GitHub you don't exist.
56 | -- Friendly developer
57 |
58 | ---
59 |
60 |
61 | # How does it work?
62 |
63 | 1. Initialize a central repository
64 | 2. Clone the repo
65 | 3. Make changes
66 | 4. Commit changes
67 | 5. Push those changes to the central repo
68 | 6. ...
69 | 7. Profit!
70 |
71 | ---
72 |
73 | # Create a new repo
74 |
75 | 
76 |
77 | ---
78 |
79 | # Clone the repo
80 |
81 | ```git clone https://github.com/jonasrosland/training-repo.git```
82 |
83 | ---
84 |
85 | # Make changes
86 |
87 | ```cd training-repo```
88 | ```echo "Hello World" > yourname.txt```
89 |
90 | ---
91 |
92 | # Commit changes
93 |
94 | ```git add yourname.txt```
95 | ```git commit -m "added yourname.txt to the repo"```
96 |
97 | ---
98 |
99 | # Push changes
100 |
101 | ```git push```
102 |
103 | ---
104 |
105 | # What happened?
106 |
107 | ---
108 |
109 | # DENIED!
110 |
111 | You're not allowed to push to this repo
112 |
113 | So how can we collaborate?
114 |
115 | Fork it!
116 |
117 | ---
118 |
119 | # Fork a repo
120 |
121 | 
122 |
123 | ---
124 |
125 | # Clone _that_ repo instead of the original one
126 |
127 | ```git clone https://github.com//training-repo```
128 |
129 | Repeat your changes, and try to push
130 |
131 | What happens?
132 |
133 | ---
134 |
135 | # Compare to the original
136 |
137 | 
138 |
139 | ---
140 |
141 | 
142 |
143 | ---
144 |
145 | # Create a pull request
146 |
147 | 
148 |
149 | ---
150 |
151 | 
152 |
153 | ---
154 |
155 | ## If a Pull Request is alright, it can then be merged
156 |
157 | ---
158 |
159 | 
160 |
161 | ---
162 |
163 | 
164 |
165 | ---
166 |
167 | # Branches
168 |
169 | ---
170 |
171 | # Why use a branch?
172 |
173 | Create a branch for every new feature or bugfix
174 |
175 | Keeps the "master" clean and with only working code
176 |
177 | You can then pull in fixes and features to the master when they're complete
178 |
179 | And then create new releases such as v1.1 or v20150215 from master
180 |
181 | ---
182 |
183 | # Releases are stable
184 |
185 | Use releases to make it easy for the community to use stable code
186 |
187 | 
188 |
189 | ---
190 |
191 | # Create a new branch
192 |
193 | ```git branch awesome-feature```
194 |
195 | 
196 |
197 | ---
198 |
199 | # Switch to your branch
200 |
201 | ```git checkout new-feature```
202 |
203 | ---
204 |
205 | # Make changes, commit, then push
206 |
207 | ```echo "Hello World again" > yourname.txt```
208 |
209 | ```git diff```
210 |
211 | ```git add yourname.txt```
212 |
213 | ```git commit -m "made some changes"```
214 |
215 | ```git push```
216 |
217 | What happens?
218 |
219 | ---
220 |
221 | # You need to set the upstream
222 |
223 | - This is where we should push the new changes to
224 |
225 | - It might be a totally different repo than the original
226 |
227 | ```git push --set-upstream origin new-feature```
228 |
229 | Now go look at that branch up on GitHub
230 |
231 | ---
232 |
233 | ## You can now create a pull request from that branch!
234 |
235 |
236 | ---
237 |
238 | A great cheat sheet:
239 |
240 | http://www.clearvision-cm.com/wp-content/uploads/2014/08/Git-Cheat-Sheet_Clearvision.pdf
241 |
--------------------------------------------------------------------------------
/devops-geekweek/Day2-Part2-12factorApp.md:
--------------------------------------------------------------------------------
1 | # The 12 factor App
2 |
3 | ^ Open this presentation with [Deckset](http://www.decksetapp.com/)
4 | ^ Matt
5 |
6 | ---
7 |
8 | ### The Basics
9 |
10 | * This was in your home work :)
11 |
12 | > much of this source: http://www.clearlytech.com/2014/01/04/12-factor-apps-plain-english/
13 |
14 | ---
15 |
16 | # \#1: Codebase
17 |
18 | * One codebase tracked in revision control, many deploys
19 | * Put all your code in a source control system. Heck, just put it up on GitHub from the start.
20 |
21 | Importance: Non-negotiable. Everyone does this, and developers will laugh at you if you aren’t.
22 |
23 | ---
24 |
25 | # \#2: Dependencies
26 |
27 | * Dependencies must be explicitly declared
28 | * They should be declared with the rest of the code, and tracked the same way
29 | * Dependencies tracking should contain version numbers of dependencies
30 |
31 | Importance: High. Without this, your team will have a constant slow time-suck of confusion and frustration, multiplied by their size and number of applications. Spare yourself.
32 |
33 | ---
34 |
35 | # \#3: Config
36 |
37 | * Config belongs in the environment if possible - it varies between deploys, but the code doesn't
38 | * Includes access credentials, logging config, etc.
39 | * Should be read at runtime, not preprocessed into code.
40 |
41 | Importance: Medium. You can get away without it, but its sloppy.
42 |
43 | ---
44 |
45 | # \#4: Backing Services
46 |
47 | * Anything your application uses as a resource (database, queueing system, email, cache) should be referenced with 'bindings' to these services.
48 | * Possibly discovered via:
49 | * Discovery mechanism (Zookeeper, etcd, Consul etc )
50 | * Environment
51 |
52 | Importance: High. Its easy to do, and follows with the Config rules above
53 |
54 | ---
55 |
56 | # \#5: Build Release Run
57 |
58 | * Build, Release and Run are separate stages for the application life cycle.
59 |
60 | > The process of turning the code into a bundle of scripts, assets and binaries that run the code is the build. The release sends that code to a server in a fresh package together with the nicely-separate config files for that environment (see Config again). Then the code is run so the application is available on those servers.
61 |
62 | ---
63 |
64 | # \#6: Processes
65 |
66 | * As a rule, you want each of those instances of running code to be stateless.
67 | * This makes your app more resilient, and easier to recover
68 |
69 | Importances: High. Makes tools like CF even possible
70 |
71 | ---
72 |
73 | # \#7: Port Binding
74 |
75 | * Your app should not assume its the only thing running on the same port
76 | * Bind an internal port/IP to external URL using load balancer
77 |
78 | Importances: Moderate. Most tools like Heroku, CF do this for you, and enforce it
79 |
80 | ---
81 |
82 | # \#8: Concurrency
83 |
84 | * An extension of 6 above.
85 | * Not necessarily required for certain aspects (single process workers, etc)
86 |
87 | Importances: Low. But it helps scale certain parts.
88 |
89 | ---
90 |
91 | # \#9: Disposability
92 |
93 | * Losing a process should be a non event
94 | * No loss of state for user if we lose a process
95 | * Startup times should be low
96 |
97 | Importances: Moderate. Makes it easy to release quickly
98 |
99 |
100 | ---
101 |
102 | # \#10: Dev / Prod Parity
103 |
104 | * Dev MUST == Production in config, but not performance
105 | * Following the above helps do this
106 |
107 | Importances: Critical. You can't do continuous push (or push at all) safely without it.
108 |
109 | ---
110 |
111 | # \#11: Logs
112 |
113 | * Log *everything*
114 | * Storage is cheap
115 | * Searching is cheap
116 | * Logs help fix problems *after* they happen
117 | * Use tokens for specific flows
118 |
119 | Importances: High. Can't debug without logs.
120 |
121 | ---
122 |
123 |
124 | # \#12: Admin Processes
125 |
126 | * Use your app/framework for these... build in the tools as needed.
127 | * Don’t run updates directly against a database
128 | * Don’t run them from a local terminal window
129 | * ChatOps can help here
130 |
131 | Importances: Moderate. Helps prevent mistakes
132 |
--------------------------------------------------------------------------------
/devops-geekweek/Day2-Part3-SprintPlanning.md:
--------------------------------------------------------------------------------
1 | # Next Steps
2 |
3 | ---
4 |
5 | * Go through the application and its code...full discussion.
6 | * Use Kanban Board (Trello, Asana whatever) to assign and prioritize tasks.
7 | * Play Sprint Poker to do estimates
8 |
--------------------------------------------------------------------------------
/devops-geekweek/Day3-Part1-WhatIsCF.md:
--------------------------------------------------------------------------------
1 | # [fit] DevOps Agile Geek Week
2 | ## Day 3
3 |
4 | ^ Open this presentation with [Deckset](http://www.decksetapp.com/)
5 | ^ Matt
6 |
7 | ---
8 |
9 | #Today's Focus:
10 |
11 | # [fit] Cloud Foundry & Related Services
12 |
13 | ---
14 |
15 | # [fit] Part 1: What's a PaaS?
16 |
17 | ---
18 |
19 | PaaS is a category of cloud computing services that provides a platform allowing customers to develop, run and manage applications without the complexity of building and maintaining the infrastructure typically associated with developing and launching an app.
20 |
21 | ---
22 |
23 |
24 | # CF 101
25 |
26 | >what problems does it solve?
27 |
28 | * managing operating systems sucks.
29 | * managing runtimes sucks
30 | * managing deployment of dependencies sucks
31 | * managing application isolation sucks
32 | * managing deployment tasks sucks
33 |
34 | ---
35 |
36 |
37 | ## Process for deploying/scaling app on EC2 / EHC / etc
38 |
39 | 1. Deploy VM (the easy part - handled by IaaS...CMDB?)
40 | 2. Secure VM (or write some puppet)
41 | 2. Install runtime (with what? rpm? tarball?)
42 | 3. install dependencies (or write some scripts)
43 | 4. Install application (tarball? RPM? git?)
44 | 5. Start application (how? job engine? keep it running?)
45 | 6. Modify load balancer (how?)
46 | 7. Modify firewall (how?)
47 | 8. Add health checks (to where? http? tcp? )
48 |
49 | ---
50 |
51 | ## Process for deploying app on CF
52 |
53 | 1. `cf push app_name`
54 |
55 | ## Process for scaling app on CF
56 |
57 | 1. `cf scale app_name -i instance_count`
58 |
59 | ---
60 |
61 | # [fit] Components
62 |
63 | ---
64 |
65 | * Cloud Controller
66 |
67 | * UAA
68 |
69 | * Diego
70 |
71 | * Loggregator
72 |
73 | * GoRouter
74 |
75 | * Buildpacks
76 |
77 | * Services
78 |
79 | * BOSH
80 |
81 | ---
82 |
83 | # Cloud Controller
84 |
85 | * API layer
86 |
87 | * `cf` cli talks to this
88 |
89 | ```
90 | mcowger@hex:~
91 | $ cf apps
92 | Getting apps in org EVP / space EMC as matt.cowger@emc.com...
93 | OK
94 |
95 | name requested state instances memory disk urls
96 | boisecode stopped 0/1 128M 1G boisecode.cfapps.io
97 | bourbonTweetAlerts started 1/1 256M 1G bourbontweetalerts.cfapps.io
98 | cfworker started 1/1 128M 1G cfworker.cfapps.io
99 | ```
100 |
101 | ---
102 |
103 | # UAA
104 |
105 | * Authentication layer
106 |
107 | * Internal or LDAP Backend
108 |
109 | * OAUTH2 Provider
110 |
111 | * Recent EMC work
112 |
113 | ---
114 |
115 |
116 | # Diego
117 |
118 | * Elastic Runtime Components
119 |
120 | * Container Management (through Garden)
121 | * Container Scheduling
122 | * Droplet Creation
123 | * Placement / Availability Management
124 | * Deployment of Applications
125 |
126 | * Recent rewrite to enable new hotness
127 |
128 | ---
129 |
130 | # Loggregator
131 |
132 | * Platform for delivering application log output
133 |
134 | * Collates as needed
135 |
136 | * `Firehose` too
137 |
138 |
139 | ##Example
140 |
141 | ```
142 | $ cf logs --recent chargers2
143 | 2015-06-02T08:45:42.48-0700 [App/0] OUT chargers2.cfapps.io - [02/06/2015:15:45:42 +0000] "GET / HTTP/1.1" 200 0 8461 ...
144 | 2015-06-02T08:45:45.06-0700 [App/1] OUT chargers2.cfapps.io - [02/06/2015:15:45:45 +0000] "GET / HTTP/1.1" 200 0 8461 ...
145 |
146 | ```
147 |
148 |
149 | ---
150 |
151 | # Gorouter
152 |
153 |
154 | * Accepts requests for a specific 'route' (URL)
155 |
156 | * Passes them to available applications & instances assigned to that route (possibly more than 1)
157 |
158 | * Can be replaced by other load balancers if needed
159 |
160 | ---
161 |
162 | # Buildpacks
163 |
164 | * Provide basis for running application:
165 |
166 | * Language runtime (`Ruby`, `Python`, `COBOL`, `Java`, etc)
167 | * Module installation (as needed)
168 | * Debugger setup (as needed)
169 | * anything language or environment specific
170 |
171 | ---
172 |
173 | # Services
174 |
175 | > no application is an island
176 |
177 | * External tools automatically provisioned & attached
178 |
179 | * Databases (MySQL, Oracle, Postgres)
180 | * NoSQL (Redis, MongoDB, etc)
181 | * Message Queues (0mq, RabbitMQ, etc)
182 |
183 |
184 | ---
185 |
186 | # BOSH
187 |
188 | * Responsible for using the IaaS (vSphere, vCD, OpenStack, AWS, etc) to build virtual machines
189 |
190 | * VMs are called 'cells'
191 |
192 | * CF on Bare Metal is coming :)
193 | * Currently based on Ubuntu
194 | * Support for VMware Photon is planned
195 |
196 | ---
197 |
198 |
199 | # BOSH, cont.
200 |
201 | * Responsible for managing:
202 |
203 | * Long Running Processes (services, apps, parts of itself)
204 | * Tasks (single run requests (deploy X, create Y))
205 | * Upgrades of infrastructure
206 |
207 |
208 | ---
209 |
210 | # Demo
211 |
212 |
213 | ---
214 |
215 |
216 | # [fit] cf push
217 |
218 |
219 |
220 | ---
221 |
222 |
223 |
224 | # [fit] now you!
225 |
226 | ```
227 | git clone https://github.com/mcowger/hello-python.git
228 | cd hello-python
229 | cf login
230 | cf push hello-
231 | ...
232 | http://hello-yourname.cfapps.io
233 |
234 | ```
235 |
--------------------------------------------------------------------------------
/devops-geekweek/Day3-Part2-CFServices.md:
--------------------------------------------------------------------------------
1 | # DevOps Agile Geek Week
2 | ## Day 3
3 |
4 | ^ Open this presentation with [Deckset](http://www.decksetapp.com/)
5 | ^ Jonas
6 |
7 | ---
8 |
9 | #Cloud Foundry Services
10 |
11 | ---
12 |
13 | * Applications don't exist in a vacuum
14 | * Databases
15 | * Messages Busses
16 | * Caching Layers
17 | * Storage Systems
18 |
19 | ---
20 |
21 | # some examples:
22 |
23 | * redis, mongodb, riak, postgresql
24 | * 0mq, rabbitMQ, redis
25 | * redis, memcached
26 | * s3, swift, atmos
27 |
28 | ---
29 |
30 | > How do we manage this without hardcoding and manual effort?
31 |
32 | ---
33 |
34 | # Service bindings
35 |
36 | 1. Create a service (from market place, or internal)
37 | * `cf create-service`
38 | * system automatically requests new service instance from service broker
39 | * broker responds with connection information
40 | 2. Bind service to application:
41 | * `cf bind-service`
42 | 3. Application gets credentials via `VCAP_SERVICES` environment variable
43 | 4. Application connects to service
44 |
45 | ---
46 |
47 | * multiple apps can be bound to same service (think databases, or message buses)
48 | * service brokers are easy to write
49 | * all instances of app all treated equally
50 |
--------------------------------------------------------------------------------
/devops-geekweek/Day3-Part3-BuildStuff.md:
--------------------------------------------------------------------------------
1 | # Tonight/tomorrow/now/whenever
2 |
3 | ---
4 |
5 | * Start implementing new features/changes as guided buy Sprint Planning
6 | * Matt + Jonas will be here to help
7 |
--------------------------------------------------------------------------------
/devops-geekweek/Day4-Part1-Logging.md:
--------------------------------------------------------------------------------
1 | #DevOps Agile Geek Week
2 |
3 | >XI. Logs
4 | Treat logs as event streams
5 |
6 | -- The 12 Factor App
7 |
8 | ^ Open this presentation with [Deckset](http://www.decksetapp.com/)
9 | ^ Jonas
10 |
11 | ---
12 |
13 | ##Microservices Drive Requirements
14 |
15 | * 10s or even 100s of microservices means a huge number of logs to comb through for an event
16 | * performance analytics become critical when you have thousands of users and interdependent services
17 |
18 | ---
19 |
20 | # Logging
21 |
22 | * log everything
23 | * no really, everything
24 | * `chargers.cfapps.io` logs ~73 MB/day
25 |
26 | ---
27 |
28 | # Logging Rules
29 |
30 | * app never concerns itself with routing or storage of its output stream
31 | * usually write to `stdout`
32 | * include deep information as to file, module, function, lineno
33 | * include a correlation id with every message
34 | * log in UTC
35 | * log with appropriate level: `debug` vs. `info` vs. `critical`
36 |
37 | ---
38 |
39 | # Logging Tools
40 |
41 | * use language-native tools for logging
42 | * python `logging`
43 | * node `winston` or `bunyan`
44 | * ruby `yell` or `logging`
45 | * configurable tools are better tools
46 | * multiple output streams are better
47 | * multiple logging levels are better
48 |
49 | ---
50 |
51 | # Log Management Tools
52 |
53 | * splunk (http://www.splunk.com)
54 | * loggly (http://www.loggly.com)
55 | * logstash (https://github.com/elasticsearch/logstash)
56 | * "ELK" stack - elasticsearch, logstash, kibana
57 | * graylog2
58 | * many others
59 |
60 | ---
61 |
62 | # Logging Tips
63 | * send all logs to `stdout` **and** logging system
64 | * set alerts on messages of give `type` per `minute|hour|whatever`
65 | * use correlation id to track a given transaction/request
66 |
67 | ---
68 |
69 | #gah, enough text! what's it look like?
70 |
71 | ---
72 |
73 | 
74 |
--------------------------------------------------------------------------------
/devops-geekweek/Day4-Part2-Instrumentation.md:
--------------------------------------------------------------------------------
1 | #DevOps Agile Geek Week
2 |
3 | >We have done so much,
4 | with so little,
5 | for so long,
6 | we are now qualified to do anything,
7 | with nothing.
8 |
9 |
10 | -- Konstantin Josef Jirečekt
11 |
12 | ^ Open this presentation with [Deckset](http://www.decksetapp.com/)
13 |
14 | ^ Matt
15 |
16 | ---
17 |
18 | # instrumentation
19 |
20 | without instrumentation of the application we lack
21 |
22 | * visibility into 'normal'
23 | * visibility into problems
24 | * the ability to identify bottlenecks
25 | * and benchmark effectively
26 | * the ability to plan for capacity
27 | * effective alerting & proactive monitoring
28 |
29 | ---
30 |
31 | # what do i mean by instrumentation?
32 |
33 | ---
34 |
35 | # easy understanding
36 |
37 | 
38 |
39 |
40 | ---
41 |
42 | # easy dashboards
43 |
44 | 
45 |
46 | ---
47 |
48 | # easy profiling
49 |
50 | 
51 |
52 |
53 | ---
54 |
55 | # tools methods
56 | * usually application integrated
57 | * imported module or similar: `import newrelic.agent`
58 | * sometimes a wrapper: `newrelic start appname.py`
59 | * uses builtin language profiling tools
60 | * logs **everything** to service
61 | * usually a hosted SaaS service
62 |
63 | ---
64 |
65 | #examples
66 |
67 | * app analytics:
68 | * new relic
69 | * datadog
70 | * stackify
71 | * AppDynamics
72 | * RayGun
73 |
--------------------------------------------------------------------------------
/devops-geekweek/Day5-Part1-DemosRetrospective.md:
--------------------------------------------------------------------------------
1 | # Demo Day!
2 |
3 | ----
4 |
5 | # Sprint Retrospective
6 |
--------------------------------------------------------------------------------
/devops-geekweek/Homework.md:
--------------------------------------------------------------------------------
1 | # Homework
2 | ## 2015 DevOps Geekweek
3 | ## Jonas Rosland & Matt Cowger
4 |
5 | ^ Open this presentation with [Deckset](http://www.decksetapp.com/). Just keep this in mind as we go through this, as its the underpinning of everything here.
6 |
7 | ---
8 |
9 | # Day 1
10 |
11 | 1. Fork and clone the https://github.com/emccode/training repo, including submodules
12 | 2. Get Python 2.7 installed somewhere (locally or in a cloud environment of some sort)
13 | 3. Understand how to install proper Python modules
14 |
--------------------------------------------------------------------------------
/devops-geekweek/README.md:
--------------------------------------------------------------------------------
1 | Cloud DevOps Immersion
2 | ----------------------
3 |
4 | #Purpose:
5 | Most technical professionals, especially presales engineers within EMC express a strong preference for lab (and even better, real hands on) work over slide training. This is even more critical when learning about methologies (ITIL, etc) as compared to specific technologies.
6 |
7 | The intent of this course is to use an immersive method to give an introduction to modern methodologies and tools in use at today's 3rd platform and web-scale startups and incubators.
8 |
9 | ##Target Areas of Education
10 | Participants of this course can expect to come away with basic hands on experience in:
11 |
12 | * Agile methodology
13 | * Distributed, public source code management
14 | * PaaS and Cloud Foundry application deployment
15 | * DevOps management methods and ideas
16 | * Basic application management/infra tools (Docker, cf, New Relic, object storage, etc)
17 |
18 | After having completed this course, any participant should be able to comfortably speak with any customer using these tools and methods without feeling underwater, and will be able to express some level of familiarity with the procedures and challenges posed by modern deployment and management methods.
19 |
20 | ##Requirements
21 | Participants should:
22 |
23 | * Be able to commit fully to the program, for the entire duration with at least 75% of their time each day. This is a critical, hard requirement to experience the course material as designed.
24 | * Have a basic understanding of virtualization, database, systems and storage concepts at a 101 level (Any EMC SE beyond Associate should be at this level).
25 | * Be able to *read* (writing not required) very basic code in at least one language. For example, be able to understand [whats happening in the following Task in at least one language at Rosetta Code](http://rosettacode.org/wiki/Read_a_file_line_by_line). This course is not focused on significant development, but some basic familiarity is important. Much of the code we will be reviewing will be written in Python, so if you want to get familiar, that would be a good place to start: [Python @ CodeAcademy](http://www.codecademy.com/en/tracks/python) - everything up until the "Advanced Python" section will be useful.
26 | * *Hardware/Software*
27 | - One of the following combos:
28 | - MacOS (10.9+)
29 | - Windows 7+ *and* a Linux VM (either with as a local VM, or on Amazon or Digital Ocean or something). Note: you could use Vagrant to do this easily :).
30 | - A webcam that works with Google Hangouts. If you have a Mac with builtin webcam, thats fine. If not, buy one and expense it.
31 |
32 | * *Command Line*
33 | - [Linux/Unix Command Line](https://www.udemy.com/linux-command-line-volume1/). You should understand how to move around on a Linux command line.
34 |
35 | * *Tools*
36 |
37 | - [Git](https://help.github.com/articles/set-up-git/): Install it from homebrew or github - doesn't matter. Make sure you install Git 2.x or above. You also need to[ setup a github account.](https://github.com/join)
38 | - [CloudFoundry CLI](http://docs.cloudfoundry.org/devguide/installcf/) - install it from CloudFoundry.org or homebrew.
39 | - [Slack](http://slack.com) - we'll invite you.
40 | - [Trello](http://trello.com) - sign up for an account.
41 | - [Google Hangouts](http://hangouts.google.com) - make sure you have a working Google account and that you can join Hangouts.
42 | - [Python 2.7](https://www.python.org/downloads/release/python-2710/) - preinstalled on MacOS and your Linux VM.
43 |
44 | * *Required reading*
45 |
46 | - [The Twelve-Factor App](http://12factor.net/) (all the in depth pages, not just the home page)
47 |
48 | * *Recommended reading*
49 |
50 | - [The Phoenix Project](http://www.amazon.com/The-Phoenix-Project-Helping-Business/dp/0988262592)
51 | - [The Goal](http://www.amazon.com/The-Goal-Process-Ongoing-Improvement/dp/0884271951)
52 |
53 | ##Basic Course Overview
54 |
55 | A basic outline of the course follows, on a day-by-day basis. Throughout the course the proctor/instructor will participate both as a team member completing work as well as mentor for individual tasks (writing code if needed, etc), as well as guiding based on Agile principles.
56 |
57 | ####Day 1:
58 | * Get acclimated to the [tools](Day1-Part1-Tools.md) in use
59 | * Discuss basic [Agile methodology](Day1-Part2-Agile101.md) and [how to apply it](Day1-Part3-AgileHowTo.md)
60 | * Do first Sprint Planning for team project, including story pointing.
61 |
62 | ####Day 2:
63 | * Daily standup
64 | * Basic tutorial on GitHub / Source Code Management
65 | * 12 Factor Apps
66 | * Team works via collaborative methods (Slack, Asana, Google Hangouts, etc) to complete tasks committed for that day.
67 | * Optional: Vagrant & Packer
68 |
69 | ####Day 3:
70 | * Daily standup
71 | * Basic tutorial on CF concepts and provisioned services.
72 | * Team works to produce basic working deployed application to CF by end of day
73 |
74 |
75 | ####Day 4:
76 | * Daily standup
77 | * Basic tutorial on application instrumentation and management (logging, application performance analytics).
78 | * Team works to add monitoring and management to application, signs up for alerts, etc.
79 | * Optional: Lattice & Terraform & Container Scheduling
80 |
81 | #### Day 5:
82 | * Daily standup
83 | * Any last minute items finished/deployed as needed.
84 | * Sprint Retrospective conducted, along with Velocity analysis
85 | * Project presented to leadership team and proctors/instructors.
86 |
--------------------------------------------------------------------------------
/devops-geekweek/images/Devops.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/Devops.png
--------------------------------------------------------------------------------
/devops-geekweek/images/base.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/base.jpg
--------------------------------------------------------------------------------
/devops-geekweek/images/basic.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/basic.png
--------------------------------------------------------------------------------
/devops-geekweek/images/bellichick.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/bellichick.jpg
--------------------------------------------------------------------------------
/devops-geekweek/images/concurrency.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/concurrency.png
--------------------------------------------------------------------------------
/devops-geekweek/images/configshuffle.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/configshuffle.png
--------------------------------------------------------------------------------
/devops-geekweek/images/criticalerror.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/criticalerror.png
--------------------------------------------------------------------------------
/devops-geekweek/images/deprecated.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/deprecated.png
--------------------------------------------------------------------------------
/devops-geekweek/images/gears.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/gears.jpg
--------------------------------------------------------------------------------
/devops-geekweek/images/github_compare.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/github_compare.png
--------------------------------------------------------------------------------
/devops-geekweek/images/github_compare2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/github_compare2.png
--------------------------------------------------------------------------------
/devops-geekweek/images/github_create_pr.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/github_create_pr.png
--------------------------------------------------------------------------------
/devops-geekweek/images/github_merge.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/github_merge.png
--------------------------------------------------------------------------------
/devops-geekweek/images/github_merge_successful.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/github_merge_successful.png
--------------------------------------------------------------------------------
/devops-geekweek/images/github_new_branch.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/github_new_branch.png
--------------------------------------------------------------------------------
/devops-geekweek/images/github_pr.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/github_pr.png
--------------------------------------------------------------------------------
/devops-geekweek/images/incremental.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/incremental.png
--------------------------------------------------------------------------------
/devops-geekweek/images/iterative.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/iterative.png
--------------------------------------------------------------------------------
/devops-geekweek/images/loggly.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/loggly.png
--------------------------------------------------------------------------------
/devops-geekweek/images/mvp_fail_01.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/mvp_fail_01.png
--------------------------------------------------------------------------------
/devops-geekweek/images/newrelicdash.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/newrelicdash.png
--------------------------------------------------------------------------------
/devops-geekweek/images/newrelicoverview.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/newrelicoverview.png
--------------------------------------------------------------------------------
/devops-geekweek/images/newrelictrace.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/newrelictrace.png
--------------------------------------------------------------------------------
/devops-geekweek/images/obama.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/obama.jpg
--------------------------------------------------------------------------------
/devops-geekweek/images/pcfopsmanager.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/pcfopsmanager.tiff
--------------------------------------------------------------------------------
/devops-geekweek/images/petversuscattle.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/petversuscattle.png
--------------------------------------------------------------------------------
/devops-geekweek/images/profiles.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/profiles.jpg
--------------------------------------------------------------------------------
/devops-geekweek/images/rca.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/rca.jpg
--------------------------------------------------------------------------------
/devops-geekweek/images/showcase.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/showcase.png
--------------------------------------------------------------------------------
/devops-geekweek/images/speakers.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/speakers.jpg
--------------------------------------------------------------------------------
/devops-geekweek/images/timebox.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/timebox.png
--------------------------------------------------------------------------------
/devops-geekweek/images/title.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/title.jpg
--------------------------------------------------------------------------------
/devops-geekweek/images/workedonmine.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/workedonmine.jpg
--------------------------------------------------------------------------------
/devops-geekweek/images/worksonmymachine.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/worksonmymachine.png
--------------------------------------------------------------------------------
/devops-geekweek/images/yaml.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/devops-geekweek/images/yaml.jpg
--------------------------------------------------------------------------------
/docker-workshops/README.md:
--------------------------------------------------------------------------------
1 | Docker Workshops
2 | ================
3 |
4 | ### Docker Platform Introduction
5 |
6 | A full-day workshop that takes the attendees from "What is Docker" to "Here's how you run a cluster of Docker hosts and schedule containers on top of them".
7 |
8 | Currently, this lab is intended to be ran locally.
9 |
10 | ### Docker with Storage and Networking
11 |
12 | A 3-hour workshop that focuses on the Docker platform 1.9+ including external storage and networking. The storage section is focused on leveraging `REX-Ray`, a storage orchestration engine, with `Docker`. The networking section is using embedded `Docker` networking through the `libNetwork` project.
13 |
14 | Currently, this lab is ran from AWS and requires that you use `docker-machine` to deploy two machines that are configured using a custom `extension` package.
15 |
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/README.md:
--------------------------------------------------------------------------------
1 | # Docker Platform Introduction Workshop
2 |
3 | A full-day workshop that gives you enough information to start planning to run Docker containers in your own organization.
4 |
5 | The workshop is intended for Docker beginners, so if you're wondering which orchestration tool you should implement or worried about how to run large-scale L2 networks this is NOT the event for you.
6 |
7 | So, if you're new to Docker and looking for a great introduction, this will is a great opportunity to get a hands-on introduction to the fundamentals.
8 |
9 |
10 | **Prerequisites:**
11 |
12 | Use your own laptop with The Docker Toolbox (https://www.docker.com/toolbox) installed.
13 |
14 | ### Agenda:
15 |
16 | #### Part I: Introduction to Docker
17 | - Overview, 1h, [presentation here](http://www.slideshare.net/jonasrosland/docker-and-containers-overview-docker-workshop)
18 | - Docker ecosystem, 20 min
19 | - Network
20 | - Storage
21 | - Management
22 |
23 | #### Lab I: Run your first container
24 |
25 | - Start it
26 | - See the logs
27 | - See which ports are open
28 | - Connect to the container
29 |
30 | #### Lab II: Building containers with Dockerfiles
31 |
32 | - Write your first Dockerfile
33 | - Build your first container
34 | - Run it and repeat the previous lab
35 |
36 | #### Part II: Docker in Production
37 |
38 | This section explores the issues in running Docker in a production environment, which is exactly what you'll want to do after the training is over :)
39 |
40 | - Introduction to clustering
41 | - CoreOS
42 | - Docker Machine and Swarm
43 | - Starting a cluster
44 | - Resource scheduling
45 | - Service discovery (etcd, Consul, Zookeeper, etc)
46 | - High availability
47 |
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/lab2-docker-compose/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM python:2.7
2 | ADD . /code
3 | WORKDIR /code
4 | RUN pip install -r requirements.txt
5 |
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/lab2-docker-compose/app.py:
--------------------------------------------------------------------------------
1 | from flask import Flask
2 | from redis import Redis
3 | import os
4 | app = Flask(__name__)
5 | redis = Redis(host='redis', port=6379)
6 |
7 | @app.route('/')
8 | def hello():
9 | redis.incr('hits')
10 | return 'Hello World! I have been seen %s times.' % redis.get('hits')
11 |
12 | if __name__ == "__main__":
13 | app.run(host="0.0.0.0", debug=True)
14 |
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/lab2-docker-compose/docker-compose.yml:
--------------------------------------------------------------------------------
1 | web:
2 | build: .
3 | command: python app.py
4 | ports:
5 | - "5000:5000"
6 | links:
7 | - redis
8 | redis:
9 | image: redis
10 |
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/lab2-docker-compose/extends/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM python:2.7
2 | ADD . /code
3 | WORKDIR /code
4 | RUN pip install -r requirements.txt
5 | CMD python app.py
6 |
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/lab2-docker-compose/extends/app.py:
--------------------------------------------------------------------------------
1 | from flask import Flask
2 | from redis import Redis
3 | import os
4 |
5 | app = Flask(__name__)
6 | redis = Redis(host=os.environ['REDIS_HOST'], port=6379)
7 |
8 | @app.route('/')
9 | def hello():
10 | redis.incr('hits')
11 | return 'Hello World! I have been seen %s times.\n' % redis.get('hits')
12 |
13 | if __name__ == "__main__":
14 | app.run(host="0.0.0.0", debug=True)
15 |
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/lab2-docker-compose/extends/common.yml:
--------------------------------------------------------------------------------
1 | web:
2 | build: .
3 | ports:
4 | - "5000:5000"
5 |
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/lab2-docker-compose/extends/docker-compose.yml:
--------------------------------------------------------------------------------
1 | web:
2 | extends:
3 | file: common.yml
4 | service: web
5 | volumes:
6 | - .:/code
7 | links:
8 | - redis
9 | environment:
10 | - REDIS_HOST=redis
11 | redis:
12 | image: redis
13 |
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/lab2-docker-compose/extends/production.yml:
--------------------------------------------------------------------------------
1 | web:
2 | extends:
3 | file: common.yml
4 | service: web
5 | environment:
6 | - REDIS_HOST=redis-production.example.com
7 |
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/lab2-docker-compose/extends/requirements.txt:
--------------------------------------------------------------------------------
1 | flask
2 | redis
3 |
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/lab2-docker-compose/requirements.txt:
--------------------------------------------------------------------------------
1 | flask
2 | redis
3 |
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/lab3-docker-swarm/README.md:
--------------------------------------------------------------------------------
1 | Create a cluster of container hosts
2 | ===============================
3 |
4 | # Description
5 |
6 | In this lab you'll use Docker Machine to set up a "swarm" of container hosts, a cluster that you can manage and schedule containers on top of.
7 |
8 | ## The Docker Swarm master
9 |
10 | We need a Swarm Master that will be our main point of contact for the entire cluster.
11 | First we need to create a discovery token, and we can use our existing container host to create one for us:
12 |
13 | ```
14 | $ docker run swarm create
15 |
16 | Status: Downloaded newer image for swarm:latest
17 | 8d7dc77346a4e0d999fd38cc29ed0d38
18 | ```
19 |
20 | The last line is our discovery token that is ours and ours alone, and we will take that token and create our Swarm Master with it:
21 |
22 | ```
23 | $ docker-machine create -d virtualbox --swarm --swarm-master --swarm-discovery token://YOURTOKENHERE swarm-master
24 | 426583efc6a swarm-master
25 | Creating VirtualBox VM...
26 | Creating SSH key...
27 | Starting VirtualBox VM...
28 | Starting VM...
29 | To see how to connect Docker to this machine, run: docker-machine env swarm-master
30 | ```
31 |
32 | We are actually using a public discovery service, so you can head over to `https://discovery.hub.docker.com/v1/clusters/YOURTOKENHERE` and see the IP address of your Swarm Master. You'll see more nodes coming up in a just a few minutes.
33 |
34 | But first, let's make sure your environment variable are correct by running the following command:
35 |
36 | `eval $(docker-machine env --swarm swarm-master)`
37 |
38 | Let's have a look at `docker info`:
39 |
40 | ```
41 | $ docker info
42 | Containers: 2
43 | Images: 1
44 | Role: primary
45 | Strategy: spread
46 | Filters: affinity, health, constraint, port, dependency
47 | Nodes: 1
48 | swarm-master: 192.168.99.100:2376
49 | └ Containers: 2
50 | └ Reserved CPUs: 0 / 1
51 | └ Reserved Memory: 0 B / 1.022 GiB
52 | └ Labels: executiondriver=native-0.2, kernelversion=4.0.9-boot2docker, operatingsystem=Boot2Docker 1.8.2 (TCL 6.4); master : aba6192 - Thu Sep 10 20:58:17 UTC 2015, provider=virtualbox, storagedriver=aufs
53 | CPUs: 1
54 | Total Memory: 1.022 GiB
55 | Name: 7bd1a650694a
56 | ```
57 |
58 | You can se we have just one node in our cluster (the Swarm Master), we have 1 CPU and 1GB or memor we can use. Let's add some more resources!
59 |
60 | ## Create Docker Swarm Nodes
61 |
62 | We will now create the nodes of our Docker Swarm so we actually have a cluster and not just a single container host.
63 |
64 | Run the following command to create your first and second node:
65 |
66 | ```
67 | $ docker-machine create -d virtualbox --swarm --swarm-discovery token://YOURTOKENHERE swarm-node1
68 | $ docker-machine create -d virtualbox --swarm --swarm-discovery token://YOURTOKENHERE swarm-node2
69 | ```
70 |
71 | Now let's run `docker info` again:
72 |
73 | ```
74 | $ docker info
75 | Containers: 4
76 | Images: 3
77 | Role: primary
78 | Strategy: spread
79 | Filters: affinity, health, constraint, port, dependency
80 | Nodes: 3
81 | swarm-master: 192.168.99.100:2376
82 | └ Containers: 2
83 | └ Reserved CPUs: 0 / 1
84 | └ Reserved Memory: 0 B / 1.022 GiB
85 | └ Labels: executiondriver=native-0.2, kernelversion=4.0.9-boot2docker, operatingsystem=Boot2Docker 1.8.2 (TCL 6.4); master : aba6192 - Thu Sep 10 20:58:17 UTC 2015, provider=virtualbox, storagedriver=aufs
86 | swarm-node1: 192.168.99.101:2376
87 | └ Containers: 1
88 | └ Reserved CPUs: 0 / 1
89 | └ Reserved Memory: 0 B / 1.022 GiB
90 | └ Labels: executiondriver=native-0.2, kernelversion=4.0.9-boot2docker, operatingsystem=Boot2Docker 1.8.2 (TCL 6.4); master : aba6192 - Thu Sep 10 20:58:17 UTC 2015, provider=virtualbox, storagedriver=aufs
91 | swarm-node2: 192.168.99.102:2376
92 | └ Containers: 1
93 | └ Reserved CPUs: 0 / 1
94 | └ Reserved Memory: 0 B / 1.022 GiB
95 | └ Labels: executiondriver=native-0.2, kernelversion=4.0.9-boot2docker, operatingsystem=Boot2Docker 1.8.2 (TCL 6.4); master : aba6192 - Thu Sep 10 20:58:17 UTC 2015, provider=virtualbox, storagedriver=aufs
96 | CPUs: 3
97 | Total Memory: 3.065 GiB
98 | Name: 7bd1a650694a
99 | ```
100 |
101 | Now you can see that we have 3 nodes, totalling 3 CPUs and 3GB of memory that we can use for our containers, awesome! Also, revisit `https://discovery.hub.docker.com/v1/clusters/YOURTOKENHERE` to see that you now have the IP addresses and ports for all three hosts.
102 |
103 | Now let's start a few containers and you'll see that are being scheduled on top of all three container hosts. When you do a `docker pull` or a `docker run`, it might seem like the process is hanging but just wait and it will eventually give you some output.
104 |
105 | ```
106 | $ docker run -d redis
107 | 5ec99f019f00d763e7dde4c1d0315f44c92e5c66ce3f9e70454168d1a227b1ff
108 | $ docker run -d nginx
109 | 8552e93bc2a02d683a342d9ba792f517b396d028b0cc6fb9aca2bd7d87fe06e7
110 | $ docker run -d postgres
111 | 6abbe9cbebc7a19773e30db4537783460f153188a1b57d0d55c7cd3e61d1653f
112 | ```
113 |
114 | Now if we look at where those containers are actually running we can see that they are on different hosts by the names they are given:
115 |
116 | ```
117 | $ docker ps
118 | CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
119 | 6abbe9cbebc7 postgres "/docker-entrypoint.s" 41 seconds ago Up 38 seconds 5432/tcp swarm-master/goofy_einstein
120 | 8552e93bc2a0 nginx "nginx -g 'daemon off" 2 minutes ago Up 2 minutes 80/tcp, 443/tcp swarm-node2/silly_bardeen
121 | 5ec99f019f00 redis "/entrypoint.sh redis" 3 minutes ago Up 3 minutes 6379/tcp swarm-node1/distracted_turing
122 | ```
123 |
124 | There you go, you now have a 3 node Docker Swarm cluster up and running on your laptop, with 3 containers scheduled across them, and using a public service discovery instance to manage your cluster.
125 |
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/lab4-coreos/README.md:
--------------------------------------------------------------------------------
1 | Multi-container apps with CoreOS
2 | ================================
3 |
4 | ## Description
5 |
6 | In this lab you'll learn how to setup CoreOS, how to use fleet and deploy several containers and link them together as one application.
7 |
8 | ## Lab setup verification
9 |
10 | Verify that you have the following software installed:
11 |
12 | 1. VirtualBox
13 | 2. Vagrant
14 | 3. Git
15 | 4. [CoreOS Vagrant setup](https://coreos.com/docs/running-coreos/platforms/vagrant/) by running
16 |
17 |
18 | ## Setting up a 3 node CoreOS cluster with Vagrant
19 |
20 | Follow the steps found [here](https://coreos.com/docs/running-coreos/platforms/vagrant/). Essentially do the following:
21 |
22 | 1. Enter the coreos-vagrant directory
23 | 2. Copy config.rb.sample to config.rb
24 | 3. Edit config.rb and set ```$num_instances=3``` and ```$update_channel='stable'```
25 | 4. Go to [https://discovery.etcd.io/new](https://discovery.etcd.io/new) and copy your discovery token.
26 | 5. Copy user-data.sample to user-data
27 | 6. Edit user-data and set your discovery token like ```discovery: https://discovery.etcd.io/YourTokenHere```
28 | 7. Run ```vagrant up```
29 | 8. After a while you can now connect the your CoreOS by running ```vagrant ssh core-01 -- -A```
30 |
31 | ## Running containers in CoreOS
32 |
33 | Please read the [documentation](https://coreos.com/docs/launching-containers/launching/launching-containers-fleet/) and follow along with the instructor.
34 | We'll cover running one container in a CoreOS cluster, verify failover functionality, create a multi-container HA setup, and get used to working with so called sidekicks and the etcd service discovery.
35 |
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/lab4-coreos/multi-container-ha/apache@.service:
--------------------------------------------------------------------------------
1 | [Unit]
2 | Description=My Apache Frontend
3 | After=docker.service
4 | Requires=docker.service
5 |
6 | [Service]
7 | TimeoutStartSec=0
8 | ExecStartPre=-/usr/bin/docker kill apache1
9 | ExecStartPre=-/usr/bin/docker rm apache1
10 | ExecStartPre=/usr/bin/docker pull coreos/apache
11 | ExecStart=/usr/bin/docker run -rm --name apache1 -p 80:80 coreos/apache /usr/sbin/apache2ctl -D FOREGROUND
12 | ExecStop=/usr/bin/docker stop apache1
13 |
14 | [X-Fleet]
15 | Conflicts=apache@*.service
16 |
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/lab4-coreos/one-container/ubuntu.service:
--------------------------------------------------------------------------------
1 | [Unit]
2 | Description=MyApp
3 | After=docker.service
4 | Requires=docker.service
5 |
6 | [Service]
7 | TimeoutStartSec=0
8 | ExecStartPre=-/usr/bin/docker kill busybox1
9 | ExecStartPre=-/usr/bin/docker rm busybox1
10 | ExecStartPre=/usr/bin/docker pull busybox
11 | ExecStart=/usr/bin/docker run --name busybox1 busybox /bin/sh -c "while true; do echo Hello World; sleep 1; done"
12 | ExecStop=/usr/bin/docker stop busybox1
13 |
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/presentations/CoreOS 101 - December 2014 - Jonas Rosland.md:
--------------------------------------------------------------------------------
1 | # CoreOS 101
2 |
3 | ### Jonas Rosland
4 | ### Developer Advocate
5 | #### @jonasrosland
6 | #### jonas.rosland@emc.com
7 | #### emccode.github.io
8 | #### April 2015
9 |
10 | ^ Run this presentation with [Deckset](http://www.decksetapp.com/)
11 |
12 | ---
13 |
14 | ## CoreOS
15 |
16 | Based on Gentoo
17 | Kernel + Containers, nothing else
18 | Built for running HA environments
19 | Updates applied automatically
20 |
21 | 
22 |
23 | ---
24 |
25 | ## Containers
26 |
27 | Docker, of course, but also others like LXC and nspawn
28 | Isolation from other applications
29 | Link containers together
30 | Less overhead than VMs
31 |
32 | Released container runtime engine Rocket recently
33 |
34 | 
35 |
36 | ---
37 |
38 | ## systemd
39 |
40 | System management daemon
41 | Services, timers and one-off jobs
42 | Logging through journal
43 |
44 | ---
45 |
46 | ## etcd
47 |
48 | Highly available Key-Value database store
49 | Provides service discovery and shared configurations
50 | Others like it are Consul and Zookeeper
51 | Provides a locking mechanism for safe(r) automatic updates
52 |
53 | Public etcd service:
54 | ```
55 | https://discovery.etcd.io/
56 | ```
57 | This is frickin awesome, as you'll see :)
58 |
59 | ---
60 |
61 | ## etcdctl command
62 |
63 | ```
64 | $ set services/db1 10.0.0.101
65 | $ set services/db2 10.0.0.102
66 | $ set services/db-master db1
67 | ```
68 |
69 | ```
70 | $ get services/db-master
71 | "db1"
72 | $ get services/db1
73 | "10.0.0.101"
74 | ```
75 |
76 | ---
77 |
78 | ## etcd automatic registration
79 |
80 | 
81 |
82 | ---
83 |
84 | 
85 |
86 | ---
87 |
88 | ## fleet
89 |
90 | Deploy docker containers on arbitrary hosts in a cluster
91 | Distribute services across a cluster using machine-level anti-affinity
92 | Maintain N instances of a service
93 | Re-scheduling on machine failure
94 | Discover machines running in the cluster
95 |
96 | ---
97 |
98 | ## fleet
99 |
100 | 
102 |
103 | ---
104 |
105 | ## Putting it all together
106 |
107 | 1. Create a systemd file for your service
108 | 2. Start the service using fleet
109 | 3. Register services in etcd
110 | 4. ...
111 | 5. Profit!
112 |
113 | ---
114 |
115 | # Demotime!
116 |
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/presentations/Docker ecosystem.md:
--------------------------------------------------------------------------------
1 | # Docker Ecosystem
2 |
3 | ### Jonas Rosland
4 | ### Developer Advocate
5 | #### @jonasrosland
6 | #### jonas.rosland@emc.com
7 | #### emccode.github.io
8 | #### April 2015
9 |
10 | ---
11 |
12 | # Basics of a container
13 |
14 | ---
15 |
16 | 
17 |
18 | ---
19 |
20 | # Service Discovery
21 |
22 | ---
23 |
24 | 
25 |
26 | ---
27 |
28 | # Examples
29 |
30 | service discovery / globally distributed key-value store
31 | - **etcd**
32 | - **consul**
33 | - **zookeeper**
34 |
35 | **crypt**: project to encrypt etcd entries
36 |
37 | **confd**: watches key-value store for changes and triggers reconfiguration of services with new values
38 |
39 | ---
40 |
41 | # Networking tools
42 |
43 | ---
44 |
45 | # Examples
46 |
47 | **flannel**: Overlay network providing each host with a separate subnet
48 |
49 | **weave**: Overlay network portraying all containers on a single network
50 |
51 | **pipework**: Advanced networking toolkit for arbitrarily advanced networking configurations
52 |
53 | ---
54 |
55 | # SocketPlane
56 |
57 | _Acquired by Docker 4 days ago_
58 |
59 | Open vSwitch Integration
60 |
61 | ZeroConf multi-host networking for Docker
62 |
63 | Elastic growth of a Docker/SocketPlane cluster
64 |
65 | Support for multiple networks
66 |
67 | Distributed IP Address Management (IPAM)
68 |
69 | ---
70 |
71 | # Scheduling, Cluster Management and Orchestration
72 |
73 | ---
74 |
75 | 
76 |
77 | ---
78 |
79 | # Examples
80 |
81 | **fleet**: scheduler and cluster management tool
82 |
83 | **marathon**: scheduler and service management tool
84 |
85 | **Swarm**: scheduler and service management tool
86 |
87 | ---
88 |
89 | # More examples
90 |
91 | **mesos**: host abstraction service that consolidates host resources for the scheduler
92 |
93 | **kubernetes**: advanced scheduler capable of managing container groups
94 |
95 | **compose**: container orchestration tool for creating container groups
96 |
97 | ---
98 |
99 | # More info
100 |
101 | https://www.mindmeister.com/389671722/docker-ecosystem
102 |
103 | https://www.digitalocean.com/community/tutorials/the-docker-ecosystem-an-introduction-to-common-components
104 |
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/presentations/Docker management overview - December 2014 - Jonas Rosland.md:
--------------------------------------------------------------------------------
1 | # Docker management overview
2 |
3 | ### Jonas Rosland
4 | ### Developer Advocate
5 | #### @jonasrosland
6 | #### jonas.rosland@emc.com
7 | #### emccode.github.io
8 | #### April 2015
9 |
10 | ^ Run this presentation with [Deckset](http://www.decksetapp.com/)
11 |
12 | ---
13 |
14 | Different types of management
15 |
16 | **Developer-focused:**
17 | - Fig
18 | - Panamax
19 |
20 | **Ops-focused:**
21 | - Kubernetes
22 | - Mesos
23 | - Fleet
24 | - Docker Swarm
25 |
26 | ---
27 |
28 | # Fig
29 |
30 | ---
31 |
32 | ## Fig
33 |
34 | Fast, isolated development environments using Docker.
35 | Orchard acquired by Docker July 2014
36 | Docker's first acquisition
37 |
38 | 
39 |
40 | ---
41 |
42 | ## Fig example (1/3)
43 |
44 | Let's define two services:
45 |
46 | **web**
47 | - built from Dockerfile
48 | - run the command python app.py inside the image
49 | - forward the exposed port 5000 on the container to port 5000 on the host machine
50 | - connect to the Redis service
51 | - mount the current directory inside the container
52 |
53 | **redis**, which uses the public image redis
54 |
55 | ---
56 |
57 | ## Fig example (2/3)
58 |
59 | Dockerfile:
60 |
61 | ```
62 | FROM python:2.7
63 | ADD . /code
64 | WORKDIR /code
65 | RUN pip install -r requirements.txt
66 | ```
67 |
68 | ---
69 |
70 | ## Fig example (3/3)
71 |
72 | fig.yml:
73 |
74 | ```
75 | web:
76 | build: .
77 | command: python app.py
78 | ports:
79 | - "5000:5000"
80 | volumes:
81 | - .:/code
82 | links:
83 | - redis
84 | redis:
85 | image: redis
86 | ```
87 | ---
88 |
89 | ## Docker Compose is Fig Next Gen
90 |
91 | ```
92 | containers:
93 | web:
94 | build: .
95 | command: python app.py
96 | ports:
97 | - "5000:5000"
98 | volumes:
99 | - .:/code
100 | links:
101 | - redis
102 | environment:
103 | - PYTHONUNBUFFERED=1
104 | redis:
105 | image: redis:latest
106 | command: redis-server --appendonly yes
107 | ```
108 |
109 | ---
110 |
111 | # Panamax
112 |
113 | ---
114 |
115 | ## Panamax
116 |
117 | An open-source project that makes deploying complex containerized apps as easy as Drag-and-Drop
118 | Created by CenturyLink Labs
119 | Released in August 2014
120 |
121 | 
122 |
123 | ---
124 |
125 | 
126 |
127 | ---
128 |
129 | ## Search for images
130 |
131 | 
132 |
133 | ---
134 |
135 | ## Run images in "apps"
136 |
137 | 
138 |
139 | ---
140 |
141 | 
142 |
143 | ---
144 |
145 | ## Manage and add more images to an app
146 |
147 | 
148 |
149 | ---
150 |
151 | ## Expose ports
152 |
153 | 
154 |
155 | ---
156 |
157 | ## Link containers together
158 |
159 | 
160 |
161 | ---
162 |
163 | # Kubernetes
164 |
165 | ---
166 |
167 | ## Kubernetes
168 |
169 | An open source system for managing containerized applications across multiple hosts
170 |
171 | Providing basic mechanisms for deployment, maintenance, and scaling of applications
172 |
173 | ---
174 |
175 | ## Kubernetes main features
176 |
177 | - lean: lightweight, simple, accessible
178 | - portable: public, private, hybrid, multi cloud
179 | - extensible: modular, pluggable, hookable, composable
180 | - self-healing: auto-placement, auto-restart, auto-replication
181 |
182 | ---
183 |
184 | ## Kubernetes concepts (1/2)
185 |
186 | **Clusters** are the compute resources on top of which your containers are built
187 |
188 | **Pods** are a colocated group of Docker containers with shared volumes - smallest deployable units that can be created, scheduled, and managed with Kubernetes
189 |
190 | ---
191 |
192 | ## Kubernetes concepts (2/2)
193 |
194 | **Replication** controllers manage the lifecycle of pods, ensuring that a specified number of pods are running at any given time, by creating or killing pods as required
195 |
196 | **Services** provide a single, stable name and address for a set of pods, acting as basic load balancers
197 |
198 | **Labels** are used to organize and select groups of objects based on key:value pairs
199 |
200 | ---
201 |
202 | 
203 |
204 | ---
205 |
206 | ## Kubernetes pod example
207 |
208 | ```
209 | {
210 | "id": "redis-master",
211 | "kind": "Pod",
212 | "apiVersion": "v1beta1",
213 | "desiredState": {
214 | "manifest": {
215 | "version": "v1beta1",
216 | "id": "redis-master",
217 | "containers": [{
218 | "name": "master",
219 | "image": "dockerfile/redis",
220 | "cpu": 100,
221 | "ports": [{
222 | "containerPort": 6379,
223 | "hostPort": 6379
224 | }]
225 | }]
226 | }
227 | },
228 | "labels": {
229 | "name": "redis-master"
230 | }
231 | }
232 | ```
233 |
234 | ---
235 |
236 | # Mesos
237 |
238 | ---
239 |
240 | ## Mesos
241 |
242 | Abstracts CPU, memory, storage, and other compute resources away from machines (physical or virtual)
243 |
244 | Enables fault-tolerant and elastic distributed systems to easily be built and run effectively
245 |
246 | 
247 |
248 | ---
249 |
250 | ## Mesos functionality
251 |
252 | The Mesos kernel runs on every machine and provides applications (e.g., Hadoop, Spark, Kafka, Elastic Search) with API’s for resource management and scheduling across entire datacenter and cloud environments
253 |
254 | Also manages containers, of course
255 |
256 | All using one API to provision and manage everything
257 |
258 | ---
259 |
260 | ## More on Mesos
261 |
262 | I highly recommend reading up on Mesosphere
263 |
264 | ---
265 |
266 | # Fin
267 |
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/presentations/EMC CODE intro.md:
--------------------------------------------------------------------------------
1 | # EMC {code} introduction
2 |
3 | ### Jonas Rosland
4 | ### Developer Advocate
5 | #### @jonasrosland
6 | #### jonas.rosland@emc.com
7 | #### emccode.github.io
8 | #### April 2015
9 |
10 | ^ Run this presentation with [Deckset](http://www.decksetapp.com/)
11 |
12 | ---
13 |
14 | 
15 |
16 | ---
17 |
18 | ## We open EMC technology to drive adoption and innovation with developers.
19 |
20 | ---
21 |
22 | ## Learn
23 |
24 | - Meetups
25 | - Online support (StackOverflow)
26 | - Free Training
27 | - Enable others
28 |
29 | ---
30 |
31 | ## Code
32 |
33 | - Open Source software
34 | - Sample code
35 | - Simulators
36 | - Sandboxes
37 |
38 | ---
39 |
40 | ## Deploy
41 |
42 | - Everything's on Github
43 | - Bring Your Own Lab
44 |
45 | ---
46 |
47 | # emccode.github.io
48 |
49 | ---
50 |
51 | ## Contact EMC {code}
52 |
53 | @EMCCode
54 |
55 | emccode@emc.com
56 |
57 | \#emccode on Freenode
58 |
59 | \#emccode-users on Google Groups
60 |
61 | emccode.github.io
62 |
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/presentations/emccode-team.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/docker-workshops/docker-platform-intro/presentations/emccode-team.png
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/presentations/images/docker-compose-hello-world.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/docker-workshops/docker-platform-intro/presentations/images/docker-compose-hello-world.png
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/presentations/images/docker-compose-hello-world2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/docker-workshops/docker-platform-intro/presentations/images/docker-compose-hello-world2.png
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/presentations/images/docker-compose-scale.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/docker-workshops/docker-platform-intro/presentations/images/docker-compose-scale.png
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/presentations/images/docker-compose-scale2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/docker-workshops/docker-platform-intro/presentations/images/docker-compose-scale2.png
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/presentations/images/docker-compose-scale3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/docker-workshops/docker-platform-intro/presentations/images/docker-compose-scale3.png
--------------------------------------------------------------------------------
/docker-workshops/docker-platform-intro/presentations/images/lorry.io.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/docker-workshops/docker-platform-intro/presentations/images/lorry.io.png
--------------------------------------------------------------------------------
/docker-workshops/docker-storage-networking/README.md:
--------------------------------------------------------------------------------
1 | 3-Hour Docker Storage and Networking Workshop Training
2 | ===============================
3 |
4 | ## Description
5 |
6 | In this session you will learn how to use the basics of Docker Engine, how to search for Docker images on Docker hub, how to run your images and connect to the applications inside them, deploy multi-container applications using Compose, build Dockerfiles, configure a Swarm cluster, use [REX-Ray](https://github.com/emccode/rexray) for storage persistence, and network containers between hosts.
7 |
8 | The workshop is intended for Docker beginners, intermediate users, and those interested in storage and networking.
9 |
10 | If you're new to Docker and looking for a great introduction, this will is a good opportunity to get a hands-on introduction to the fundamentals of the Docker Platform.
11 |
12 | To get started on your own outside the classroom, follow the directions specified in [/prep/readme](https://github.com/emccode/training/blob/master/docker-storage-networking/prep/README.md) to get your AWS instances started. The slides are available at [Docker 1.9 Workshop](http://www.slideshare.net/EMCCODE/docker-19-workshop).
13 |
14 | ### Part I: Introduction to the Docker Platform
15 | - Overview & Intro Presentation (20 minutes)
16 |
17 | ### Lab I: Run your first container
18 |
19 | - Start it
20 | - See the logs
21 | - See which ports are open
22 | - Connect to the container
23 |
24 | ### Lab II: Create A Compose File
25 |
26 | - Install Docker Compose
27 | - Create a python application
28 | - Create a Dockerfile
29 | - Deploy the App
30 |
31 | ### Lab III: Create A Swarm Cluster
32 |
33 | - Get a Swarm ID
34 | - Configure Swarm Agents
35 | - Configure Swarm Master
36 | - Deploy containers to Swarm pool
37 |
38 | ### Lab IV: Container Persistence
39 |
40 | - Slide on storage persistence and it's necessity
41 | - Tour of [REX-Ray](https://github.com/emccode/rexray)
42 | - Create Volume with [REX-Ray](https://github.com/emccode/rexray)
43 | - Demo persistence between container instances
44 | - Docker 1.9 Enhanced Storage features
45 | - Create volume with Docker Volume commands
46 | - Demo persistence between host instances
47 |
48 | ### Lab V: Networking Between Container Hosts
49 |
50 | - Destroy Existing Swarm Setup
51 | - Create New Swarm using Consul
52 | - Create overlay networks
53 | - Attach containers to networks
54 | - Verify connectivity between containers
55 |
--------------------------------------------------------------------------------
/docker-workshops/docker-storage-networking/lab2-create-a-compose-file/README.md:
--------------------------------------------------------------------------------
1 | Lab II: Create A Compose File
2 | ===============================
3 |
4 | ## Description
5 |
6 | In this lab you'll learn how to create a Docker Compose file to programmatically deploy an application with code. We will also learn how to use a Dockerfile. A Dockerfile is a text document that contains all the commands a user could call on the command line to assemble an image. Compose is a tool for defining and running multi-container applications with Docker. With Compose, you define a multi-container application in a single file, then spin your application up in a single command which does everything that needs to be done to get it running.
7 |
8 | ### Lab setup
9 |
10 | Each participant has been handed a piece of paper with two machines `student00Xa` and `student00Xb` with their associated IP addresses. Each machine has been provisioned by Docker Machine with Docker 1.9 and REX-Ray 0.2 installed for use. The SSH password for each host is the host name. ie. Host `student001a`'s password is `student001a`
11 |
12 | #### Mac/Linux
13 | Use Terminal
14 | `ssh IPADDRESS -l student001a`
15 |
16 | #### Windows
17 | Use PuTTy
18 |
19 | ## Install Compose
20 | Before we begin, we have to install Docker Compose. As of this writing, the latest release is [v1.5.0](https://github.com/docker/compose/releases)
21 |
22 | ```
23 | $ sudo -s
24 | $ curl -L https://github.com/docker/compose/releases/download/1.5.0/docker-compose-`uname -s`-`uname -m` > /usr/local/bin/docker-compose
25 | $ chmod +x /usr/local/bin/docker-compose
26 | $ exit
27 | ```
28 |
29 | ## Create an Application
30 | We will follow the steps as listed on [Docker Compose Quickstart](https://docs.docker.com/compose/)
31 |
32 | Create a new directory to host the compose file
33 | ```
34 | $ cd ~
35 | $ mkdir composetest
36 | $ cd composetest
37 | ```
38 |
39 | Inside this directory, create app.py, a simple web app that uses the Flask framework and increments a value in Redis.
40 | ```
41 | $ nano app.py
42 | ```
43 |
44 | copy and paste the following into `app.py`. Use `CTRL+X` and `Y` to save the file:
45 | ```
46 | from flask import Flask
47 | from redis import Redis
48 |
49 | app = Flask(__name__)
50 | redis = Redis(host='redis', port=6379)
51 |
52 | @app.route('/')
53 | def hello():
54 | redis.incr('hits')
55 | return 'Hello World! I have been seen %s times.' % redis.get('hits')
56 |
57 | if __name__ == "__main__":
58 | app.run(host="0.0.0.0", debug=True)
59 | ```
60 |
61 | Next, define the Python dependencies in a file called `requirements.txt`:
62 | ```
63 | nano requirements.txt
64 | ```
65 |
66 | Copy and paste:
67 | ```
68 | flask
69 | redis
70 | ```
71 |
72 | Now, create a Docker image containing all of your app’s dependencies. You specify how to build the image using a file called `Dockerfile`:
73 |
74 | ```
75 | nano Dockerfile
76 | ```
77 |
78 | There are more settings of course, and we'd recommend you to read up on them at the [Dockerfile reference](https://docs.docker.com/reference/builder/).:
79 |
80 | Copy and paste:
81 | ```
82 | FROM python:2.7
83 | ADD . /code
84 | WORKDIR /code
85 | RUN pip install -r requirements.txt
86 | CMD python app.py
87 | ```
88 |
89 | Next, define a set of services using `docker-compose.yml`:
90 | ```
91 | nano docker-compose.yml
92 | ```
93 |
94 | The following `docker-compose.yml` file defines two containers `web` and `redis` that are connected via specifying the `links` parameter. The content of the container is specified in two ways. First int the `web` container, it is told to `build: .` which ensures the `Dockerfile` specified above with the Python app is built. The `redis` container specifies `image: redis` which ensures an official image of `redis` is pulled. The `web` container has a `ports:` parameter specified which exposes the `5000` port to the outside world. The last portion is related to the exposing this working directory to the `web` container, this is done through the `volumes` parameter with `.:/code`. Check out all the other attributes at the [docker-compose.yml reference](https://docs.docker.com/compose/yml/).
95 |
96 | Copy and paste:
97 | ```
98 | web:
99 | build: .
100 | ports:
101 | - "5000:5000"
102 | volumes:
103 | - .:/code
104 | links:
105 | - redis
106 | redis:
107 | image: redis
108 | ```
109 |
110 | Now lets run it!:
111 | ```
112 | $ docker-compose up
113 | ```
114 |
115 | You are presented with the logging output of both containers. Access the application by going to `http://PUBLICIP:5000` Refresh the page and watch the log.
116 |
117 | Now, we can't render our host useless by looking at logs. So stop the container by pressing `CTRL+c`. A `docker ps` will show that these containers have been stopped. Bring them up again in a detached state.:
118 | ```
119 | docker-compose up -d
120 | ```
121 | Go back to your web application at `http://PUBLICIP:5000` and you'll see that it's all working.
122 |
123 | ```
124 | Hello World! I have been seen 1 times.
125 | ```
126 |
127 | Try refreshing and you will see that the `redis` container is holding our state, and maintains an incremented counter for every page load. With a `refresh` you should see this.
128 |
129 | Press `ctrl-c` to stop the application.
130 |
131 |
132 | ## Congratulations!!
133 | You have created your first multi-container appliation using `Docker Compose`.
134 |
--------------------------------------------------------------------------------
/docker-workshops/docker-storage-networking/prep/README.md:
--------------------------------------------------------------------------------
1 | 3-Hour Docker Workshop Training Prep
2 | ====================================
3 |
4 | If you are in a classroom environment, you will be given two machines listed as `studentXYZa` and `studentXYZb` where `XYZ` is a number.
5 |
6 | If you are doing this workshop on your own, you will need to deploy the hosts on your own. Download `rexconfig.yml`, `student.json`, and `dockertraining.sh` to a local folder.
7 |
8 | Edit `rexconfig.yml` with your AWS ACCESS & SECRET KEYS. Edit `student.json` to make sure `rexconfig.yml` and `dockertraining.sh` are in an available directory.
9 |
10 | The `docker-machine` AWS security group should have the following ports open
11 |
12 | | Protocol | Port Range
13 | | ---------|:----------:|
14 | | TCP | 3376 |
15 | | TCP | 80 |
16 | | TCP | 8080 |
17 | | TCP | 7946 |
18 | | TCP | 5000 |
19 | | TCP | 2376 |
20 | | TCP | 2375 |
21 | | UDP | 4789 |
22 | | TCP | 443 |
23 | | TCP | 8888 |
24 | | TCP | 22 |
25 | | TCP | 3375 |
26 | | TCP | 8500 |
27 |
28 | Using [Docker Machine with the experimental EMC {code} extension framework](http://blog.emccode.com/2015/09/26/make-docker-machine-do-anything-with-our-experimental-extensions/) deploy a host. Each student needs 2 hosts.
29 |
30 | Download this unsupported binary and make it executable (example for Mac OS X):
31 | ```
32 | $ curl -L https://github.com/kacole2/machine/releases/download/v0.5.0-dev-ext/docker-machine_darwin-amd64 > /usr/local/bin/docker-machine
33 | $ chmod +x /usr/local/bin/docker-machine
34 | ```
35 |
36 | Use this binary to provision your hosts for the workshop:
37 |
38 | #### For US-East-1 (default) (AMI using Ubuntu 14.04.03 with Kernel 3.19-30)
39 | ```
40 | $ docker-machine -D create --driver amazonec2 --amazonec2-access-key --amazonec2-secret-key --amazonec2-vpc-id --amazonec2-zone "b" --amazonec2-ami ami-f6e6979c --engine-install-url "https://get.docker.com" --extension /Users/kcoleman/Desktop/student.json student001a
41 |
42 | $ docker-machine -D create --driver amazonec2 --amazonec2-access-key --amazonec2-secret-key --amazonec2-vpc-id --amazonec2-zone "b" --amazonec2-ami ami-f6e6979c --engine-install-url "https://get.docker.com" --extension /Users/kcoleman/Desktop/student.json student001b
43 | ```
44 |
45 | #### For EU-West-1 (AMI using Ubuntu 14.04.03 with Kernel 3.19-30)
46 | ```
47 | $ docker-machine -D create --driver amazonec2 --amazonec2-access-key --amazonec2-secret-key --amazonec2-region "eu-west-1" --amazonec2-ami ami-0ab16e79 --amazonec2-vpc-id --engine-install-url "https://test.docker.com" --extension /Users/kcoleman/Desktop/student.json student001a
48 |
49 | $ docker-machine -D create --driver amazonec2 --amazonec2-access-key --amazonec2-secret-key --amazonec2-region "eu-west-1" --amazonec2-ami ami-0ab16e79 --amazonec2-vpc-id --engine-install-url "https://test.docker.com" --extension /Users/kcoleman/Desktop/student.json student001b
50 | ```
51 |
52 | #### AMI ID's in all regions.
53 | Docker 1.9 Networking Requires a kernel version of 3.16 or greater.
54 |
55 | | Region | AMI-ID
56 | | -------------------|:------------:|
57 | | US-East-1 | ami-f6e6979c |
58 | | US-West-2 | ami-d79284b6 |
59 | | US-West-1 | ami-fe2c429e |
60 | | AP-Northeast-1 | ami-2c547542 |
61 | | SA-East-1 | ami-a0e258cc |
62 | | EU-West-1 | ami-0ab16e79 |
63 |
--------------------------------------------------------------------------------
/docker-workshops/docker-storage-networking/prep/dockertraining.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 | useradd -s /bin/bash -m -d /home/$HOSTNAME -g root $HOSTNAME
3 | echo -e "$HOSTNAME\n$HOSTNAME\n" | sudo passwd $HOSTNAME
4 | sed -i '20 a '"$HOSTNAME"' ALL=(ALL:ALL) ALL' /etc/sudoers
5 | sed -i 's/PasswordAuthentication no/PasswordAuthentication yes/g' /etc/ssh/sshd_config
6 | gpasswd -a ${HOSTNAME} docker
7 | reboot
--------------------------------------------------------------------------------
/docker-workshops/docker-storage-networking/prep/example:
--------------------------------------------------------------------------------
1 |
2 | for i in {02..12};
3 | do
4 | studenta=student$(printf "%03d" $i)a;
5 | studentb=student$(printf "%03d" $i)b;
6 | ~/Downloads/docker-machine_darwin-amd64 rm -f $studenta
7 | ~/Downloads/docker-machine_darwin-amd64 rm -f $studentb
8 | ~/Downloads/docker-machine_darwin-amd64 -D create --driver amazonec2 --amazonec2-access-key accessKey --amazonec2-secret-key secretKey --amazonec2-vpc-id vpc-c5d35ba0 --amazonec2-region "us-east-1" --amazonec2-zone "c" --amazonec2-subnet-id subnet-e47992cf --amazonec2-ami ami-f6e6979c --engine-install-url "https://get.docker.com" --extension ./student.json $studenta &&
9 | ~/Downloads/docker-machine_darwin-amd64 -D create --driver amazonec2 --amazonec2-access-key accessKey --amazonec2-secret-key secretKey --amazonec2-vpc-id vpc-c5d35ba0 --amazonec2-region "us-east-1" --amazonec2-zone "c" --amazonec2-subnet-id subnet-e47992cf --amazonec2-ami ami-f6e6979c --engine-install-url "https://get.docker.com" --extension ./student.json $studentb
10 | done
11 |
--------------------------------------------------------------------------------
/docker-workshops/docker-storage-networking/prep/rexconfig.yml:
--------------------------------------------------------------------------------
1 | ---
2 | storageDrivers:
3 | - libstorage
4 | libstorage:
5 | host: "127.0.0.1:1870"
6 | drivers:
7 | - ec2
8 | profiles:
9 | enabled: true
10 | client: false
11 | groups:
12 | - groupName=127.0.0.1
13 | aws:
14 | accessKey: secretKey
15 | secretKey: accessKey
16 |
--------------------------------------------------------------------------------
/docker-workshops/docker-storage-networking/prep/student.json:
--------------------------------------------------------------------------------
1 | {
2 | "extensions": [
3 | {
4 | "generic": {
5 | "run": [
6 | "wget https://dl.bintray.com/akutz/rexray/unstable/0.3.0-dev+11/rexray-Linux-x86_64-0.3.0-dev+11.tar.gz",
7 | "tar -zxvf rexray-Linux-x86_64-0.3.0-dev+11.tar.gz",
8 | "sudo mv rexray /usr/bin/.",
9 | "sudo rexray install"
10 | ],
11 | "validOS": [
12 | "ubuntu",
13 | "debian"
14 | ]
15 | }
16 | },
17 | {
18 | "generic": {
19 | "copy": {
20 | "/Users/clintonkitson/Repos/training/docker-workshops/docker-storage-networking//prep/rexconfig.yml":"/etc/rexray/config.yml"
21 | }
22 | }
23 | },
24 | {
25 | "generic": {
26 | "run": [
27 | "GROUP=`hostname | sed 's/[ab]//'` && sudo sed -i s/groupName/$GROUP/g /etc/rexray/config.yml"
28 | ]
29 | }
30 | },
31 | {
32 | "generic": {
33 | "run": [
34 | "sudo rexray start"
35 | ]
36 | }
37 | },
38 | {
39 | "generic": {
40 | "copy": {
41 | "/Users/clintonkitson/Repos/training/docker-workshops/docker-storage-networking//prep/dockertraining.sh": "/tmp/training.sh"
42 | },
43 | "validOS": [
44 | "ubuntu",
45 | "debian"
46 | ]
47 | }
48 | },
49 | {
50 | "generic": {
51 | "run": [
52 | "sudo bash /tmp/training.sh"
53 | ],
54 | "validOS": [
55 | "ubuntu",
56 | "debian"
57 | ]
58 | }
59 | }
60 | ]
61 | }
62 |
--------------------------------------------------------------------------------
/mesos-workshop/Apache-Mesos-Workshop-HandsOnLab.md:
--------------------------------------------------------------------------------
1 | ## Agenda
2 |
3 | 1. Instructor Demo
4 | 2. Hands on use by audience
5 | - use a laptop or browser on your phone
6 |
7 | ---
8 |
9 | ## Pre- deployed Mesos Cluster
10 |
11 | - A Mesos Master is deployed, and it is also running Zookeeper
12 | - hostname: TBD:5050
13 | - A Marathon host is deployed
14 | - hostname: TBD:8080
15 | - A Chronos host is deployed
16 | - hostname: TBD:4400
17 | - Multiple Mesos slave nodes are deployed
18 | - Users do not deal with these directly
19 |
20 | ---
21 |
22 | ## Instructor Demo
23 |
24 | 1. Deploy a Python web server using Marathon UI
25 | - python -m SimpleHTTPServer $PORT
26 | 2. Show how to scale the application and halt the application
27 |
28 | ---
29 |
30 | ## Demonstrate use of the Marathon REST API
31 |
32 | compose a .json file with this content, on the Marathon host:
33 |
34 | ```
35 | {
36 | "id": "web-server-via-rest-api",
37 | "cmd": "echo 'Hello Mesos fans' > readme-$PORT.txt && python -m SimpleHTTPServer $PORT",
38 | "mem": 16,
39 | "cpus": 0.1,
40 | "instances": 6,
41 | "constraints": [
42 | ["hostname", "UNIQUE"]
43 | ]
44 | }
45 | ```
46 |
47 | ---
48 |
49 | ## Marathon REST API continued
50 |
51 | 1. Use curl to call the API
52 |
53 | ```
54 | curl -i -H 'Content-Type: application/json' -d @test.json localhost:8080/v2/apps
55 | ```
56 |
57 | ---
58 |
59 | ## Fault detection and recovery Demo
60 |
61 | 1. Kill an application instance using command line on the agent host running it.
62 | - ps -aux | grep SimpleHTTPServer
63 | - kill #
64 | 3. Observe Mesos detect this condition and bring the web server back up
65 |
66 | ---
67 |
68 | ## Audience Hands On
69 |
70 | 1. Explore the Marathon GUI, using you laptop, tablet, or phone
71 | 2. Install deploy a simple Python web server using the Marathon GUI
72 | - echo 'phrase of your choice' > yourname && python -m SimpleHTTPServer $PORT
73 | 3. Test that your web server is alive at the assigned cluster node / port
74 | 4. Scale the application and halt the application
75 |
76 | ---
77 |
78 | ## Optional, if time allows
79 |
80 | 1. Instructor demo of using Chronos UI to deploy a periodically scheduled job.
81 | - browse to Chronos host:4400
82 | - create a job
83 | - name: chronos-sleeper-job
84 | - command: sleep 40
85 | - owner: test@test.com
86 | - schedule: edit to end in PT5M
87 |
--------------------------------------------------------------------------------
/mesos-workshop/README.md:
--------------------------------------------------------------------------------
1 | Mesos Workshop
2 | ================
3 |
4 | ### Mesos Introduction
5 |
6 | A 2 hour workshop that takes the attendees from "What is Mesos" to a hands-on deployment of a web server on a Mesos cluster.
7 |
8 | Covers:
9 |
10 | - What is Mesos? and What can it do for me?
11 | - What kinds of workloads can it support?
12 | - How large can it scale, and how does its performance hold up at scale?
13 | - How would I go about deploying it?
14 | - How does Mesos compare to other schedulers / cluster managers?
15 | - Mesos features and roadmap related to external and persistent storage
16 |
17 | ---
18 |
19 | ### Presentation flow:
20 |
21 | 1. Present deck #1(35-45 minutes)
22 | 2. Hands-on lab (20-30 minutes)
23 | - Attendees utilize the Marathon UI to deploy a web server, so they can use a laptop, tablet , or smartphone that can connect to AWS hosts.
24 | 3. Wrapup with Deck #2
25 | 4. Q&A
26 |
27 | ---
28 |
29 | ### Pre-configured lab setup
30 |
31 | The hands-on lab portion of this workshop anticipates a preconfigured Mesos cluster in AWS - though nothing inherently precludes running in another cloud or on "bare metal".
32 |
33 | A workshop for 30 attendees can be done with 9 AWS instances, deployed as follows.
34 |
35 | 1. t2.micro running
36 | - Ubuntu 14.04
37 | - Mesos Master
38 | - Zookeeper
39 | 2. t2.micro running
40 | - Ubuntu 14.04
41 | - Mesos Master
42 | - Zookeeper
43 | - Marathon
44 | 3. t2.micro running
45 | - Ubuntu 14.04
46 | - Mesos Master
47 | - Zookeeper
48 | - Chronos
49 | 4. 6 instances of t2.micro running
50 | - Ubuntu 14.04
51 | - Mesos Slave
52 | - Python, Golang installed
53 | - Docker installed (optional)
54 | - RexRay and DVDCLI installed (optional)
55 | 5. AWS security group with ports open on
56 | - 22 (ssh)
57 | - 4400 (Chronos)
58 | - 5050 (Mesos Master)
59 | - 8080 (Marathon)
60 | - 31000-32000 (ephemeral ports for attendee web servers)
--------------------------------------------------------------------------------
/mesos-workshop/images/Mesos Hosts.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/mesos-workshop/images/Mesos Hosts.png
--------------------------------------------------------------------------------
/mesos-workshop/images/Mesos application support.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/mesos-workshop/images/Mesos application support.png
--------------------------------------------------------------------------------
/mesos-workshop/images/Mesos-Users.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/mesos-workshop/images/Mesos-Users.png
--------------------------------------------------------------------------------
/mesos-workshop/images/mesos frameworks.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/mesos-workshop/images/mesos frameworks.png
--------------------------------------------------------------------------------
/mesos-workshop/images/mesos overview.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/mesos-workshop/images/mesos overview.png
--------------------------------------------------------------------------------
/mesos-workshop/images/mesos paper screenshot.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/mesos-workshop/images/mesos paper screenshot.png
--------------------------------------------------------------------------------
/mesos-workshop/images/wired mesos screenshot.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/mesos-workshop/images/wired mesos screenshot.png
--------------------------------------------------------------------------------
/one-day-geekweek/agenda.md:
--------------------------------------------------------------------------------
1 | class: center, middle
2 |
3 | # One Day DevOps / Agile / Cloud Native Geek Week
4 |
5 | A single day, heavy duty, partially hands-on introduction to discussions around cloud native applications, the methods used to develop them, the ideas behind the architecture and some of the tools in use.
6 |
7 | ---
8 |
9 | ## Prework
10 |
11 | (this is real prework - we will reference this stuff often, and you *will* fall behind)
12 |
13 | * Read The Phoenix Project, by Gene Kim
14 | * Install `git`: [Windows](https://git-scm.com/download/win) & [Mac](https://git-scm.com/download/mac)
15 | * Install `cf cli` [Windows](https://cli.run.pivotal.io/stable?release=windows64&source=github) & [Mac](https://cli.run.pivotal.io/stable?release=macosx64&source=github)
16 |
17 | ---
18 |
19 | ##[Part 1](index.html?slide=part1):
20 | * Definititions & Why
21 | * DevOps?
22 | * Agile?
23 | * Cloud Native?
24 |
25 | ##[Part 2](index.html?slide=part2):
26 | * Basic concepts & drivers behind Agile methods
27 | * Why Agile - the manifesto
28 | * Basic mechanics of one style (SCRUM)
29 |
30 | ---
31 |
32 | ##[Part 3](index.html?slide=part3):
33 | * Cloud Native Applications
34 | * Why they are 'taking over'
35 | * The 12 Factors
36 |
37 | ##[Part 4](index.html?slide=part4):
38 | * Cloud Native Platforms
39 | * Ops Management + Services + Runtime
40 | * Prescriptive vs. Unstructured
41 |
42 | ---
43 |
44 | ##[Part 5](index.html?slide=part5):
45 |
46 | * Source Code Management
47 | * Why it matters
48 | * Infrastructure as Code
49 | * Basics of `git`: `checkout`, `forking`, `commit`, `push`, `pull` requests
50 | * *Hands On*: `clone`, `edit`, `commit` a repo.
51 |
52 | ---
53 |
54 | ##[Part 6](index.html?slide=part6):
55 | * Cloud Foundry
56 | * Base Components
57 | * Where it runs / how
58 | * Developer & Operator Experience
59 | * *Hands On*: `cf push` checked out app
60 |
61 | ---
62 |
63 | ##[Part 7](index.html?slide=part7)
64 |
65 | What can we sell?
66 |
67 | * DevOps Transformation Services
68 | * Neutrino & Project Bravo
69 | * DSSD
70 | * ECS & Rubicon
71 | * vCloud Air / Virtustream
72 |
73 | ---
74 |
75 | # Role Play Scenarios
76 |
--------------------------------------------------------------------------------
/one-day-geekweek/images/Devops.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/Devops.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/base.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/base.jpg
--------------------------------------------------------------------------------
/one-day-geekweek/images/basic.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/basic.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/bellichick.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/bellichick.jpg
--------------------------------------------------------------------------------
/one-day-geekweek/images/byo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/byo.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/cna.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/cna.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/cnpcomponents.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/cnpcomponents.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/concurrency.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/concurrency.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/configshuffle.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/configshuffle.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/criticalerror.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/criticalerror.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/deprecated.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/deprecated.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/gears.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/gears.jpg
--------------------------------------------------------------------------------
/one-day-geekweek/images/github_compare.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/github_compare.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/github_compare2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/github_compare2.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/github_create_pr.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/github_create_pr.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/github_merge.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/github_merge.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/github_merge_successful.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/github_merge_successful.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/github_new_branch.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/github_new_branch.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/github_pr.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/github_pr.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/incremental.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/incremental.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/iterative.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/iterative.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/loggly.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/loggly.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/mvp_fail_01.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/mvp_fail_01.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/newrelicdash.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/newrelicdash.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/newrelicoverview.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/newrelicoverview.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/newrelictrace.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/newrelictrace.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/obama.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/obama.jpg
--------------------------------------------------------------------------------
/one-day-geekweek/images/pcf.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/pcf.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/pcfopsmanager.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/pcfopsmanager.tiff
--------------------------------------------------------------------------------
/one-day-geekweek/images/petversuscattle.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/petversuscattle.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/profiles.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/profiles.jpg
--------------------------------------------------------------------------------
/one-day-geekweek/images/rca.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/rca.jpg
--------------------------------------------------------------------------------
/one-day-geekweek/images/showcase.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/showcase.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/speakers.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/speakers.jpg
--------------------------------------------------------------------------------
/one-day-geekweek/images/structurecomponents.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/structurecomponents.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/timebox.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/timebox.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/title.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/title.jpg
--------------------------------------------------------------------------------
/one-day-geekweek/images/traditionalapp.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/traditionalapp.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/workedonmine.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/workedonmine.jpg
--------------------------------------------------------------------------------
/one-day-geekweek/images/worksonmymachine.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/worksonmymachine.png
--------------------------------------------------------------------------------
/one-day-geekweek/images/yaml.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/thecodeteam/training/0d310c8e97dd1976c384b2a4950e09d6c0020549/one-day-geekweek/images/yaml.jpg
--------------------------------------------------------------------------------
/one-day-geekweek/part1.md:
--------------------------------------------------------------------------------
1 | Things DevOps 'is':
2 |
3 | * culture and operational model
4 | * focuses on fast feedback cycles
5 | * sustainability
6 |
7 | ---
8 |
9 | Things DevOps is not:
10 |
11 | * A group
12 | * A person
13 | * A set of tools
14 | * Puppet
15 | * A workload
16 |
17 | ---
18 |
19 | Advantages:
20 |
21 | * 200x faster time to market
22 | * 2x goal achievement rate
23 | * 60x fewer failures
24 |
25 | ---
26 |
27 | # Would you like that?
28 |
29 | ---
30 |
31 | #thought so.
32 |
33 | ---
34 |
35 | # So, Agile?
36 |
37 | ---
38 |
39 | The Manifesto:
40 |
41 | * Individuals and interactions over processes and tools
* Working software over comprehensive documentation
* Customer collaboration over contract negotiation
* Responding to change over following a plan.
42 |
43 | ---
44 |
45 | 
46 |
47 | ---
48 |
49 | #Cool, so Cloud Native?
50 |
51 | ---
52 |
53 | its all about the promises, baby.
54 |
55 | * Traditional Apps expect the infrastructure to make a strong reliability promise
56 | * Cloud Native Apps expect the infrastructure to make a strong scale promise
57 |
58 | ---
59 |
60 | 
61 | 
62 |
--------------------------------------------------------------------------------
/one-day-geekweek/part2.md:
--------------------------------------------------------------------------------
1 | # Agile 101
2 |
3 | > - You can't gather all the requirements up front
4 | - The requirements you do gather **will** change
5 | - There is always more to do than time and money will allow
6 |
7 | -- The Agile Samurai, J. Rasmusson
8 |
9 |
10 |
11 | ---
12 |
13 | > 19% of software projects are considered "failed", 52% "challenged"
14 |
15 | > 29% actually succeeding (OnTime, OnBudget with a satisfactory result)
16 |
17 | -- 2015 study by [The Standish Group](http://www.infoq.com/articles/standish-chaos-2015)
18 |
19 | ---
20 |
21 | #Why Agile?
22 |
23 | * Too many projects not delivered
24 | * Software taking too long to get to market
25 | * Requirements not met
26 | * High costs to make changes after delivery
27 | * Having to “get it right” first time/up front
28 | * Too many defects
29 | * Unhappy Customers
30 | * Unhappy Developers
31 |
32 | ---
33 |
34 | # Software Development Methodologies
35 | * "Code-fix” (or no process)
36 | * Structured, heavy weight methodologies a.k.a.
37 | “Plan Driven Methodologies” and “Waterfall”
38 |
39 | ---
40 | # Software Development Methodologies (cont)
41 |
42 | * Largely influenced by _traditional engineering_ and _quality processes_ in industries
43 | * Desire to make software development more _predictable_, _measurable_ and _efficient_
44 | * Strong emphasis on _detailed planning_ and then _executing to the plan_
45 |
46 | ---
47 |
48 | # But Software is Different
49 |
50 | * Is not Tangible
51 | * Is not based on Mathematics
52 | * Needs Knowledge Workers
53 |
54 | ---
55 |
56 | # Relevance
57 | ###Heavy weight methodologies are most successful when:
58 |
59 | - Requirements are stable
60 | - Technology is well known and mature
61 | - Everything happens as one would expect
62 | - We are not taking on anything new or unknown
63 | - Coding is ‘copy and paste’
64 |
65 | ---
66 |
67 | # That's not true for most projects though
68 |
69 | ---
70 |
71 | # Projects with these characteristics are few and far between
72 |
73 | Heavy weight methodologies work in some instances, but there are high costs, and the risk in using them in dynamic environments is high.
74 |
75 | ---
76 |
77 | # Origins Of Agile
78 |
79 | ###Agile Methods are a reaction to:
80 |
81 | * Rigidity of heavy weight methods
82 | * Bureaucracy introduced by heavy weight methods
83 | * Unpleasant surprises due to lack of visibility
84 | * **The myth that a well-defined process is more valuable than the people who use it**
85 |
86 | ---
87 |
88 | # Agile Follows Systems Thinking
89 | * System Thinking is a way of looking at how things influence each other as a whole and not as individual parts
90 | * Focus on Flow, not Function
91 | * Look at the end-to-end process and the value we deliver to our customers
92 | * What do our customers value
93 | * How do we respond to the demands from our customers, as a system
94 |
95 | ---
96 |
97 | # Agile Follows Lean Thinking
98 | * Add nothing but value (eliminate waste)
99 | * Flow value from demand (delay commitment)
100 | * Minimize inventory (minimize intermediate artifacts)
101 | * Optimize across the organization
102 |
103 | ---
104 |
105 | # The Agile Manifesto
106 |
107 | ---
108 |
109 | >We are uncovering better ways of developing software by doing it and helping others do it. Through this work we have come to value:
110 |
111 | * Individuals and interactions over processes and tools
112 | * Working software over comprehensive documentation
113 | * Customer collaboration over contract negotiation
114 | * Responding to change over following a plan.
115 |
116 | >That is, while there is value in the items on the right, we value the items on the left more.
117 |
118 | ---
119 |
120 | #12 Principles of Agile
121 |
122 | * Our highest priority is to satisfy the customer through early and continuous delivery of valuable software.
123 | * Welcome changing requirements, even late in development.
124 | * Deliver working software frequently, with a preference to the shorter timescale.
125 |
126 | ---
127 |
128 | #12 Principles of Agile (cont)
129 |
130 | * Business people and developers must work together throughout the project.
131 | * Build projects around motivated individuals. Give them the environment and support they need, and trust them to get the job done.
132 | * The most efficient and effective method of conveying information is face-to-face conversation.
133 |
134 | ---
135 |
136 | #12 Principles of Agile (cont)
137 |
138 | * Working software is the primary measure of progress.
139 | * Agile processes promote sustainable development. The sponsors, developers, and users should be able to maintain a constant pace indefinitely.
140 | * Continuous attention to technical excellence and good design enhances agility.
141 |
142 | ---
143 |
144 | #12 Principles of Agile (cont)
145 |
146 | * Simplicity - the art of maximizing the amount of work not done - is essential.
147 | * The best architectures, requirements, and designs emerge from self-organizing teams.
148 | * At regular intervals, the team reflects on how to become more effective, then tunes and adjusts its behaviour accordingly.
149 |
150 | ---
151 |
152 | #(Common) Agile Project Lifecycle
153 | ## Timeboxed iterations
154 | 
155 |
156 | ---
157 |
158 | # The Basics
159 | 
160 |
161 | ---
162 |
163 | # Lifecycle
164 |
165 | 
166 |
167 | ---
168 |
169 | # Iterative
170 |
171 | 
172 |
173 | ---
174 |
175 | # Incremental
176 |
177 | 
178 |
179 | ---
180 |
181 | # Minimum Viable Product (MVP)
182 |
183 | 
184 |
185 | ---
186 |
187 | # Agile Myths
188 |
189 | * No Planning
190 | * No Documentation
191 | * Lacks Discipline
192 | * Limited to Co-Located Teams
193 | * Open Ended
194 |
195 | ---
196 |
197 | #Agile 'Basics'
198 |
199 | ---
200 |
201 | # Backlog
202 |
203 | The Product Owner is responsible for creating a list of things he/she wants done, called a backlog. They have exclusive rights to prioritize this backlog of work.
204 |
205 | ---
206 |
207 | As an end user, I want an app that:
208 |
209 | * grabs images from twitter
210 | * filters by hash tag
211 |
212 | so that
213 |
214 | I have a better view of the sentiment for my topic
215 |
216 | ---
217 |
218 | # Product Owner
219 |
220 | The one person responsible for a project’s success
221 |
222 | The Product Owner leads the development effort by conveying his or her vision to the team, outlining work in the scrum backlog, and prioritizing it based on business value
223 |
224 | Determines what needs to be built in 30 days or less
225 |
226 | ---
227 |
228 | # Development Teams
229 |
230 | Those responsible for committing work to the project
231 |
232 | Builds what is needed in 30 days or less and then demos it
233 |
234 | Based on the demo the Product Owner determines what to build next
235 |
236 | ---
237 |
238 | # Scrum Master
239 | Serves as a facilitator for both the Product Owner and the team
240 |
241 | He or she has no management authority within the team and may never commit to work on behalf of the team
242 |
243 | ---
244 |
245 | # Sprint Planning Meeting
246 |
247 | * Timeboxed to 4 hrs
248 | * This meeting is a _conversation_ between the Product Owner and the team
249 | * The team has the power to push back and voice concerns or impediments
250 | * Definition of 'done'
251 |
252 | ---
253 |
254 | # Sprint Planning Meeting
255 |
256 | * Product owner leaves the room
257 | * Team determines task breakdown and assignments
258 |
259 | ---
260 |
261 | # Stand Ups
262 |
263 | * Daily meeting to answer:
264 | * What I did yesterday
265 | * What I plan to do today
266 | * Anything preventing me from doing that (blockers)
--------------------------------------------------------------------------------
/one-day-geekweek/part3.md:
--------------------------------------------------------------------------------
1 | #Cloud Native Applications
2 |
3 | > Why are they taking over?
4 |
5 | ---
6 |
7 | ...because of all those reasons we mentioned earlier:
8 |
9 | they are...
10 |
11 | * faster to develop & deploy
12 | * less risky to develop & deploy
13 | * cheaper to run & deploy
14 | * more portable
15 | * easier to fit into agile & devops models
16 |
17 | ---
18 |
19 | > but what *is* a cloud native application?
20 |
21 | aka: stop handwaving!
22 |
23 | ---
24 |
25 | # The 12 factor App
26 |
27 | ---
28 |
29 | ### The Basics
30 |
31 | > much of this source: http://www.clearlytech.com/2014/01/04/12-factor-apps-plain-english/
32 |
33 | ---
34 |
35 | # \#1: Codebase
36 |
37 | * One codebase tracked in revision control, many deploys
38 | * Put all your code in a source control system. Heck, just put it up on GitHub from the start.
39 |
40 | Importance: Non-negotiable. Everyone does this, and developers will laugh at you if you aren’t.
41 |
42 | ---
43 |
44 | # \#2: Dependencies
45 |
46 | * Dependencies must be explicitly declared
47 | * They should be declared with the rest of the code, and tracked the same way
48 | * Dependencies tracking should contain version numbers of dependencies
49 |
50 | Importance: High. Without this, your team will have a constant slow time-suck of confusion and frustration, multiplied by their size and number of applications. Spare yourself.
51 |
52 | ---
53 |
54 | # \#3: Config
55 |
56 | * Config belongs in the environment if possible - it varies between deploys, but the code doesn't
57 | * Includes access credentials, logging config, etc.
58 | * Should be read at runtime, not preprocessed into code.
59 |
60 | Importance: Medium. You can get away without it, but its sloppy.
61 |
62 | ---
63 |
64 | # \#4: Backing Services
65 |
66 | * Anything your application uses as a resource (database, queueing system, email, cache) should be referenced with 'bindings' to these services.
67 | * Possibly discovered via:
68 | * Discovery mechanism (Zookeeper, etcd, Consul etc )
69 | * Environment
70 |
71 | Importance: High. Its easy to do, and follows with the Config rules above
72 |
73 | ---
74 |
75 | # \#5: Build Release Run
76 |
77 | * Build, Release and Run are separate stages for the application life cycle.
78 |
79 | > The process of turning the code into a bundle of scripts, assets and binaries that run the code is the build. The release sends that code to a server in a fresh package together with the nicely-separate config files for that environment (see Config again). Then the code is run so the application is available on those servers.
80 |
81 | ---
82 |
83 | # \#6: Processes
84 |
85 | * As a rule, you want each of those instances of running code to be stateless.
86 | * This makes your app more resilient, and easier to recover
87 |
88 | Importances: High. Makes tools like CF even possible
89 |
90 | ---
91 |
92 | # \#7: Port Binding
93 |
94 | * Your app should not assume its the only thing running on the same port
95 | * Bind an internal port/IP to external URL using load balancer
96 |
97 | Importances: Moderate. Most tools like Heroku, CF do this for you, and enforce it
98 |
99 | ---
100 |
101 | # \#8: Concurrency
102 |
103 | * An extension of 6 above.
104 | * Not necessarily required for certain aspects (single process workers, etc)
105 |
106 | Importances: Low. But it helps scale certain parts.
107 |
108 | ---
109 |
110 | # \#9: Disposability
111 |
112 | * Losing a process should be a non event
113 | * No loss of state for user if we lose a process
114 | * Startup times should be low
115 |
116 | Importances: Moderate. Makes it easy to release quickly
117 |
118 |
119 | ---
120 |
121 | # \#10: Dev / Prod Parity
122 |
123 | * Dev MUST == Production in config, but not performance
124 | * Following the above helps do this
125 |
126 | Importances: Critical. You can't do continuous push (or push at all) safely without it.
127 |
128 | ---
129 |
130 | # \#11: Logs
131 |
132 | * Log *everything*
133 | * Storage is cheap
134 | * Searching is cheap
135 | * Logs help fix problems *after* they happen
136 | * Use tokens for specific flows
137 |
138 | Importances: High. Can't debug without logs.
139 |
140 | ---
141 |
142 |
143 | # \#12: Admin Processes
144 |
145 | * Use your app/framework for these... build in the tools as needed.
146 | * Don’t run updates directly against a database
147 | * Don’t run them from a local terminal window
148 | * ChatOps can help here
149 |
150 | Importances: Moderate. Helps prevent mistakes
151 |
152 |
153 | ---
154 |
155 | ## Best Practices
156 |
157 | not requirements, not rules, but good ideas for success.
158 |
--------------------------------------------------------------------------------
/one-day-geekweek/part4.md:
--------------------------------------------------------------------------------
1 | #Cloud Native Platforms
2 |
3 | ---
4 |
5 | A place to run your cloud native applications, with varying levels of assumptions and controls.
6 |
7 | ---
8 |
9 | # Two Primary Categories
10 |
11 | ---
12 |
13 | ##"Unstructured"
14 |
15 | * Ultra-flexible
* Max Opportunity For Optimization
* For Companies Where Platform = Core Competency
* Common In Saas Startups Where There Are Relatively Few Apps
---
16 |
17 | ---
18 |
19 | 
20 |
21 | ---
22 |
23 | 
24 |
25 | ---
26 |
27 | ##"Prescriptive" / "Structured"
28 |
29 | * Opinionated
* Fastest & Reliable Outcome
* Largest Community Of Talent
* Common In Enterprise Where There Are Many Apps
30 |
31 | ---
32 |
33 | 
34 |
35 | ---
36 |
37 | 
38 |
39 | ---
40 |
41 | # The Cloud Foundry Haiku
42 | > Here is my source code
43 |
44 | > Run it on the cloud for me
45 |
46 | > I do not care how
47 | >
48 | -- [Onsi Fakhouri](https://twitter.com/onsijoe)
49 |
50 | ---
51 |
52 | #Which One Is Right?
53 |
54 | ---
55 |
56 | #Unstructured
57 |
58 | ---
59 |
60 | background-image: url(http://thelibertarianrepublic.com/wp-content/uploads/2015/09/Uber-Logo.jpg)
61 |
62 | ---
63 |
64 | background-image: url(https://d2ygrtdi28m8fp.cloudfront.net/corporateAssets/Netflix_Logo_DigitalVideo_0701.jpg)
65 |
66 | ---
67 |
68 | #Structured
69 |
70 | ---
71 |
72 | background-image: url(http://www.mprisk.org/UserFiles/Servers/Server_84508/Image/Logos/Humana%20hum_mdm_rgb_pos.png)
73 |
74 | ---
75 |
76 | background-image: url(https://upload.wikimedia.org/wikipedia/commons/thumb/5/52/Philips_logo_new.svg/2000px-Philips_logo_new.svg.png)
--------------------------------------------------------------------------------
/one-day-geekweek/part5.md:
--------------------------------------------------------------------------------
1 | #Source Code Management
2 |
3 | ---
4 |
5 | # Why use version control
6 |
7 | - Version control records changes that are made so you can recall specific version later
8 | - Makes it possible for you to work on a feature/bug fix/release without changing production code
9 | - No more "file-version3.py" or "config-020315.conf"!
10 | - Since everything is pure text it's easy to "merge" new code into existing
11 |
12 | ---
13 |
14 | # Git
15 |
16 | A distributed version control system, where every user has a complete and full copy of the source code.
17 |
18 | If you can't check it in, you can't keep track of it, so you can't version it, so you can't automate it.
19 |
20 | *Everything* belongs in source code control, and git is the standard in 3rd platform.
21 |
22 | Other possible options: subversion (svn), mercurial (hg), Perforce (p4), ClearCase (cc).
23 |
24 | ---
25 |
26 | #GitHub
27 |
28 | A freemium service to host Git repositories (repos). Public repos are free, private ones are still cheap.
29 |
30 | Most open source projects are hosted and collaborated on here.
31 |
32 | > If you're not on GitHub you don't exist.
33 | -- Friendly developer
34 |
35 | ---
36 |
37 | #Using Git
38 |
39 | (you have `git` installed, right? It was in the prework!)
40 |
41 | ---
42 |
43 | #Clone A Repo
44 |
45 | `git clone https://github.com/jonasrosland/training-repo.git`
46 |
47 | Now, explore that repo folder:
48 |
49 | * `cd foo` = change to director `foo`
50 | * `cd ..` = move up to parent directory
51 | * `ls` or `dir` = show the directory contents
52 |
53 | ---
54 |
55 | #Make A Change
56 |
57 | Edit a file in notepad or textedit. Save it.
58 |
59 | Back in the CLI, run: `git status`
60 |
61 | ---
62 |
63 | #Commit That Change
64 |
65 | `git commit -a -m "My Changes Are Awesome"`
66 |
67 | ---
68 |
69 | #Revert that commit
70 |
71 | `git reset --soft HEAD~`
72 |
73 | ---
74 |
75 | #Cool!
76 |
77 | ---
78 |
79 | #Infrastructure As Code
80 |
81 | ##Imagine If:
82 | * Your switches could be updated like that?
83 | * Servers could be deployed like that?
84 | * You didn't write 'as built' documentation, because your code *was* documentation?
85 |
86 | ---
87 |
88 | #Real World
89 |
90 | 
91 |
92 | ---
93 |
94 | #KCG: What Happened
95 |
96 | * Manual deployment of new trading software
97 | * 7 of 8 servers correctly updated
98 | * Old function still alive on the 8th server led to…
99 |
100 | ---
101 |
102 | #$440 million loss...
103 | #in 45 minutes
--------------------------------------------------------------------------------
/one-day-geekweek/part6.md:
--------------------------------------------------------------------------------
1 | # Cloud Foundry
2 |
3 | ---
4 |
5 | A Cloud Native Platform for people who want to get stuff done.
6 |
7 | ---
8 |
9 |
10 | # CF 101
11 |
12 | >what problems does it solve?
13 |
14 | * managing operating systems sucks.
15 | * managing runtimes sucks
16 | * managing deployment of dependencies sucks
17 | * managing application isolation sucks
18 | * managing deployment tasks sucks
19 |
20 | ---
21 |
22 | ## Process for deploying/scaling app on EC2 / EHC / etc
23 |
24 | * Deploy VM (the easy part - handled by IaaS...CMDB?)
25 | * Secure VM (or write some puppet)
26 | * Install runtime (with what? rpm? tarball?)
27 | * install dependencies (or write some scripts)
28 | * Install application (tarball? RPM? git?)
29 | * Start application (how? job engine? keep it running?)
30 | * Modify load balancer (how?)
31 | * Modify firewall (how?)
32 | * Add health checks (to where? http? tcp? )
33 |
34 | ---
35 |
36 | # Components:
37 | * Router
38 | * UAA
39 | * Cloud Controller / Health Manager
40 | * Elastic Runtime / Diego
41 | * Blob Store
42 | * Services
43 | * Doppler / Loggregator
44 |
45 | ---
46 |
47 | 
48 |
49 | ---
50 |
51 | #Let's Try It
52 |
53 | (you have cf cli installed, right)?
54 |
55 | ---
56 |
57 | * Clone this repo: `git clone https://github.com/mcowger/hello-python.git`
58 | * Login to `cf`: `cf login`
59 | * target `api.run.pivotal.io`
60 | * This is Pivotal Web Services
61 | * Move into the directory:
62 | * `cd hello-python`
63 | * `cd version2`
64 | * `cf push`
65 |
66 | ---
67 |
68 | # Things that just happened:
69 |
70 | * Deploy Container
71 | * Install runtime
72 | * install dependencies
73 | * Install application
74 | * Start application
75 | * Modify load balancer
76 | * Modify firewall
77 | * Add health checks
--------------------------------------------------------------------------------
/one-day-geekweek/part7.md:
--------------------------------------------------------------------------------
1 | # What Can I Sell?
2 |
3 | ---
4 |
5 | * DevOps Transformation Services
6 | * talk to Bart Driscoll
7 |
8 | ---
9 |
10 |
11 | * Neutrino & Native Hybrid Cloud
12 | * Description coming post announcement
13 | * VxRail & VxRack
14 |
15 | ---
16 |
17 | * DSSD
18 | * ECS 2.2 & EOS2
19 | * vCloud Air / Virtustream
--------------------------------------------------------------------------------