PyCon 2014

Introducción a Docker

Amjith Ramanujam  · 

Presentación

Vídeo

Transcripción

Extracto de la transcripción automática del vídeo realizada por YouTube.

it who will be doing an intro to dokur talk please give him a hand and let's get it started thank you hello everyone welcome to the introductory talk on docker as Carlos mention my name is I'm Jeff I go by I'm jet are on Twitter but so I work for

a company called New Relic and we use darker in many internal projects i'm going to explain a very specific example where we use it and how we solve this particularly hairy problem but more on that ladder i want to set the stage for why do we want to learn

about darker why is it important why is worth your time so let's get started by explaining a typical web stack it you know you have your front end server apache and genetics and your back-end server like unicorn you whiskey or mod wsgi and then you run

jingle on top of that it's not it doesn't stop right there I mean you have your database which could be postcards my sequel and then you're caching layer and your background task manager and you know if you are in your attic customer then you have

new I like to monitor all of these different pieces if you have if you happen to be a full stack developer you could be modifying any of these layers and come deployment time you check everything you run your unit tests everything works great you run it on

your local machine to make sure that you know you haven't broken anything and everything looks great you look feel confident and then you start rolling out to deploy half an hour later you find out that none of your customers are able to pay so you hurriedly

roll everything back and then you know try to start debugging and that can be anywhere from looking at log files to try to reproduce your production environment by you know exactly matching a minor version of your engine x2 Django and and trying to recreate

the problem and you know like half a day later you'll find out that there's an environment variable that you forgot to set in the production environment does that sound familiar to anyone at all oh good i'm not the only one so doctor is supposed

to solve this problem in a very unique way the way it handles this is your development environment will be exactly the same as your production environment the reason for that is because whatever you develop in will be the one that actually gets deployed in

production and I'm going to show you how that how you could do that and and we'll look at a lot of different features of dr. but before we actually get started or Before we jump into that I want to start by answering a very simple question what is

darker since this is a technology conference I presume no one's here thinking it's about Dockers the trousers company right a lot of disappointed faces well you put them one leg at a time and unless you're a Superman please wear the underwear inside

and yeah I'm just I'm just kidding a darker is an internal project that was started by dark cloud in 2013 so it's a fairly young project but it has a very active community around it in fact the project was so wildly successful the company actually

pivoted and changed their name to darker ink and it's a project that's written in go and as I mentioned it has a very active community which is very welcoming and helpful this is a definition taken straight out of dockers website that says doctor is

an open source engine that automates deployment of any application as a lightweight portable self-sufficient container that will run virtually anywhere when they said virtually anywhere they mean in Linux machines and and to make it even complicated in modern

Linux machines with a recent colonel but apart from that the definition is actually pretty good actually it's a it's a fairly accurate description of what doctor does if you're familiar with chroot or bsd jails and or solara zones then doctor is

a similar technology which provides sandboxing for a process you it allows you to run your process in a little sandbox that doesn't you know interact with outside of its container and and other things so for this particular sandboxing it uses linux containers

and linux containers have been in the linux mainline kernel for about five years i think so it's a very stable technology that they're using and dark arisen is a interface on top of that that makes easy for you to interact with these Linux containers

and in addition to just you know being a sitting on top of Linux containers it also provides some additional features that makes it easy to use which is a union file system which we'll see what it means in a little bit and you know a nice versioning system

kind of like get but not quite as powerful and a REST API that allows you to interact with the doctor to contrast this with a with a virtual machine you have your bare metal on which you run your host operating system and you know you run vmware or virtual

box which is your hypervisor layer and then you install a full guest operating system inside of that which is you know bin to or send toss or anything and you know but multiple libraries and Django and and then you run your app inside of that now if you want

to create another one of these instances in a different box then you have to go through the same process even in the same box you have to go through the same process of actually installing the guest operating system or you know launching a whole another snapshot

of your existing vm which can be quite expensive and kind of resource hungry comparing that to a docker container you have your bare metal and your host our operating system which is Linux in this case and if you install darker then docker sits as a demon

that runs on your machine and any time you launch a container it gets launched from an image we'll get into the terminology definition of what an images and in just a minute but it launches the image and multiple containers can share the same library because

[ ... ]

Nota: se han omitido las otras 2.917 palabras de la transcripción completa para cumplir con las normas de «uso razonable» de YouTube.