SlideShare a Scribd company logo
Continuous Integration with
Docker and Bamboo
STEVE SMITH • DEVOPS ADVOCATE • ATLASSIAN • @TARKASTEVE
https://bitbucket.org/ssmith/atlascamp2015-docker-ci
© http://www.amigosdosbichos.org/
Warning:
Bad analogies coming up…
VMs vs Containers
Huffington Post
Virtual Machine
Virtual HW
BIOS/EFI
Guest FS / Kernel
Applications
Physical Hardware
Host FS / Kernel
VM Hypervisor
BIOS/EFI
Virtual HW
BIOS/EFI
Guest FS / Kernel
Applications
Containers / Docker
Physical Hardware
Host FS / Kernel
Docker
Engine
BIOS/EFI
Guest FS
Application
Guest FS
Application Virtual HW
BIOS/EFI
Guest FS / Kernel
Applications
Physical Hardware
Host FS / Kernel
VM Hypervisor
BIOS/EFI
Virtual HW
BIOS/EFI
Guest FS / Kernel
Applications
Using features of the Linux kernel
Docker
libcontainer
systemd
nspawn
libvirt
cgroups
CPU accounting
Namespaces
Posix capabilities
btrfs
OverlayFS
LXC
Unix: chroot
Containers take this further…
Network
Abstraction
Process
Isolation
Filesystem
Isolation
Resource
Limits
Docker takes this to the next level…
Build Tools Packaging
Lifecycle Communication Dev (boot2docker)
Sharing
boot2docker
Virtual Hardware
Host FS / Kernel
BIOS/EFI
Guest FS
Application
Guest FS
Application
Quick Demo
Peter Kastner
Docker Concepts
Carlsberg
Docker containers are like OO classes…
Inheritance
Sourcefile
(Dockerfile) Compile
Dep. Injection Declarative Deps
FROM ubuntu:trusty
RUN apt-get update && 
apt-get install -y nginx && 
apt-get clean
EXPOSE 80
EXPOSE 443
CMD nginx -g daemon off;
Single inheritance
Add member
Override parent behaviour
Exposed linking points
Dockerfile ~= Sourcefile
Inheritance resolved at runtime
Ubuntu
Add nginx
Add run command
(sorta like JVM class assembly)
Union Filesystem
- AUFS
- BTRFS
- Devicemapper
- OverlayFS
‘run’ instantiates a new container
Ubuntu
Add nginx
Add run command
Writable
Immutable
(kinda like ‘new’)
Runtime layer
[ssmith] $ docker build -q --tag=mynginx docker/mynginx/
Sending build context to Docker daemon 12.72 MB
Sending build context to Docker daemon
Step 0 : FROM ubuntu:trusty
---> 8eaa4ff06b53
Step 1 : RUN apt-get update && apt-get install -y nginx && apt-get clea
---> Running in f05a4a034fe3
---> 1e84ac75dd9a
Removing intermediate container f05a4a034fe3
Step 2 : EXPOSE 80
---> Running in 77602b8eb9ec
---> 4076f56233ff
Removing intermediate container 77602b8eb9ec
Step 3 : EXPOSE 443
---> Running in b627b8c1d328
---> f5a3ff140964
Removing intermediate container b627b8c1d328
Step 4 : CMD nginx -g daemon off;
---> Running in 132573fe4fc9
---> c1df0408cf70
‘build’ compiles to binary
Inspecting the stack
[ssmith] $ docker history mynginx
IMAGE CREATED CREATED BY
606f0f611cb2 6 days ago /bin/sh -c #(nop) CMD [nginx -g daemon off;]
27d0fad8620d 6 days ago /bin/sh -c #(nop) EXPOSE map[443/tcp:{}]
dc26b50e9806 6 days ago /bin/sh -c #(nop) EXPOSE map[80/tcp:{}]
7a04b014a0a7 6 days ago /bin/sh -c apt-get update && apt-get install
b39b81afc8ca 9 days ago /bin/sh -c #(nop) CMD [/bin/bash]
615c102e2290 9 days ago /bin/sh -c sed -i 's/^#s*(deb.*universe)$/
837339b91538 9 days ago /bin/sh -c echo '#!/bin/sh' > /usr/sbin/polic
53f858aaaf03 9 days ago /bin/sh -c #(nop) ADD file:ca5b63647c6b7a419e
511136ea3c5a 19 months ago
Linked Containers
(dependency injection; sort-of…)
Docker host
postgresql client
--link postgresql:pg
can refer to
hostname pg
in commands
Volumes
Docker host
/var/volume1
DATA
/var/volume2
/var/volume1
client1
/var/volume2
--volumes-from DATA
(haven’t got a class analogy for this one)
Discussion
Testing with Docker
The example project
?
https://bitbucket.org/ssmith/atlascamp2015-docker-ci
The example project
Transfer
Trigger / Async
Data
Data
(See http://bit.do/postgres-es for details)
How to test…
Vagrant?
Dependencies
everywhere?
Docker?
Docker testing
Reuse images Startup speed Idempotent tests
Dev / Test match Deploy to Docker
Creating our images
Elasticsearch Dockerfile
FROM java:openjdk-7-jre
ENV ES_VER 1.3.4
ENV ES_URL https://download.elasticsearch.org/elasticsearch/elasticsearch/
elasticsearch-${ES_VER}.tar.gz
WORKDIR /opt/
RUN adduser --system elasticsearch
RUN curl ${ES_URL} -o elasticsearch.tgz && 
tar xzf elasticsearch.tgz && 
ln -s elasticsearch-${ES_VER} elasticsearch && 
mkdir /opt/elasticsearch/data/ && chown elasticsearch /opt/elasticsearch/data/ && 
mkdir /opt/elasticsearch/logs/ && chown elasticsearch /opt/elasticsearch/logs/ && 
rm elasticsearch.tgz
EXPOSE 9200
EXPOSE 9300
USER elasticsearch
CMD /opt/elasticsearch/bin/elasticsearch -f
Elasticsearch build
[ssmith] docker build -q --tag=elasticsearch docker/elasticsearch/
Sending build context to Docker daemon 2.56 kB
Sending build context to Docker daemon
Step 0 : FROM java:openjdk-7-jre
---> b797b3ba124d
Step 1 : ENV ES_VER 1.3.4
---> Running in 4842001c48d0
---> 2717f23208b7
Removing intermediate container 4842001c48d0
Step 2 : ENV ES_URL https://download.elasticsearch.org/elasticsearch/elasticsearch/
elasticsearch-${ES_VER}.tar.gz
---> Running in b2f574153a18
---> a292b608b854
Removing intermediate container b2f574153a18
Step 3 : WORKDIR /opt/
---> Running in 0f138382e071
---> aa2ebf2e8061
Removing intermediate container 0f138382e071
Step 4 : RUN adduser --system elasticsearch
---> Running in 0800878ae8c0
---> 2b0c2619f328
Removing intermediate container 0800878ae8c0
Step 5 : RUN curl ${ES_URL} -o elasticsearch.tgz && tar xzf elasticsearch.tgz &&
ln -s elasticsearch-${ES_VER} elasticsearch && mkdir /opt/elasticsearch/data/ &&
chown elasticsearch /opt/elasticsearch/data/ && mkdir /opt/elasticsearch/logs/ &&
Postgresql Dockerfile
FROM postgres:9.2
ENV POSTGRES_USER customer
COPY testschema.sql /
COPY init-test-db.sh /docker-entrypoint-initdb.d/
Postgresql init file
#!/bin/bash
echo "#### Create test DB ####"
gosu postgres postgres --single <<EOF
CREATE USER customer PASSWORD 'customer';
CREATE DATABASE customer OWNER customer;
GRANT ALL PRIVILEGES ON DATABASE customer TO customer;
EOF
echo "#### Initialise test DB ####"
gosu postgres postgres --single customer -j < /testschema.sql
echo
echo "#### Test DB initialised ####"
Postgresql build
[ssmith] docker build -q --tag=postgres docker/postgres/
Sending build context to Docker daemon 5.12 kB
Sending build context to Docker daemon
Step 0 : FROM postgres:9.2
---> 898ba6de4072
Step 1 : ENV POSTGRES_USER customer
---> Running in 932957e34d5e
---> 91b679d67fd9
Removing intermediate container 932957e34d5e
Step 2 : COPY testschema.sql /
---> 65b67419fe54
Removing intermediate container 54298baaa088
Step 3 : COPY init-test-db.sh /docker-entrypoint-initdb.d/
---> b6d84236c1f7
Removing intermediate container f9000db9da92
Successfully built b6d84236c1f7
Transfer Dockerfile
FROM java:openjdk-7-jre
# Install netcat for waitport
RUN apt-get update && 
apt-get install -y netcat-openbsd && 
apt-get clean
COPY docker/waitport /usr/local/bin/
RUN curl https://raw.githubusercontent.com/technomancy/leiningen/stable/bin/lein -o /
usr/local/bin/lein && 
chmod a+rx /usr/local/bin/lein
RUN adduser --disabled-password --gecos '' transfer
ADD . /code
RUN chown -R transfer.transfer /code
USER transfer
WORKDIR /code
RUN lein deps
CMD waitport elasticsearch 9200 && 
waitport postgres 5432 && 
lein test-out junit
Running Tests Manually
Manual run
[ssmith] docker run -d —name=postgres postgres
181470ed78836c9285664c18f0d5b4c6a9069d28c4f71b9d621d4c24762ad938
[ssmith] docker run -d --name=elasticsearch elasticsearch
5718e1ba9b7caf0e25f53d803a128d2a3d4d518ae8d747b843cc2cbdd78620ce
[smith] docker run --link postgres:postgres --link elasticsearch:elasticsearch transfer
Waiting for TCP connection to elasticsearch:9200...OK
Waiting for TCP connection to postgres:5432...OK
Received notification for accountupdate for 55d3290b-5baa-4ca6-b353-cacf5b104c60
Performing update of 55d3290b-5baa-4ca6-b353-cacf5b104c60
Indexing row 55d3290b-5baa-4ca6-b353-cacf5b104c60 Mr. 55d3290b 55d3290b Esq.
Dispatch complete
Manual cleanup
[ssmith] docker ps
CONTAINER ID IMAGE COMMAND CREATED …
5718e1ba9b7c elasticsearch:latest "/bin/sh -c '/opt/el 5 minutes ago …
181470ed7883 postgres:latest "/docker-entrypoint. 6 minutes ago …
[ssmith] docker kill elasticsearch postgres
elasticsearch
postgres
[ssmith] docker ps
CONTAINER ID IMAGE COMMAND CREATED …
[ssmith] docker ps -a
CONTAINER ID IMAGE COMMAND CREATED
ff6e5409d8ba transfer:latest "/bin/sh -c 'waitpor 11 minutes ago
5718e1ba9b7c elasticsearch:latest "/bin/sh -c '/opt/el 11 minutes ago
181470ed7883 postgres:latest "/docker-entrypoint. 11 minutes ago
[smith] docker rm transfer postgres elasticsearch
transfer
postgres
elasticsearch
Simplifying with Compose
feedyourskull.com
Compose automates Docker
Compose
Declarative Deps Fetch Images Build Images
Link Containers
Our docker-compose.yml
transfer:
build: .
links:
- postgres
- elasticsearch
postgres:
build: docker/postgres
elasticsearch:
build: docker/elasticsearch
Compose Run
[ssmith] docker-compose up
Creating devweek15code_postgres_1...
Creating devweek15code_elasticsearch_1...
Creating devweek15code_transfer_1...
Attaching to devweek15code_postgres_1, devweek15code_elasticsearch_1, devweek15code_transfer_1
postgres_1 | The files belonging to this database system will be owned by user "postgres".
postgres_1 | This user must also own the server process.
<SNIP> <SNIP> <SNIP> <SNIP> <SNIP>
transfer_1 | Waiting for TCP connection to postgres:5432...OK
transfer_1 | Received notification for accountupdate for dcf286bf-7011-40f5-abb0-153d94acde
transfer_1 | Performing update of dcf286bf-7011-40f5-abb0-153d94acde69
transfer_1 | Indexing row dcf286bf-7011-40f5-abb0-153d94acde69 Mr. dcf286bf dcf286bf Esq.
elasticsearch_1 | creating index, cause [auto(index api)], shards [5]/[1], mappings []
elasticsearch_1 | update_mapping [account] (dynamic)
transfer_1 | Dispatch complete
devweek15code_transfer_1 exited with code 0
Gracefully stopping... (press Ctrl+C again to force)
Stopping devweek15code_elasticsearch_1...
Stopping devweek15code_postgres_1...
Compose Cleanup
[ssmith] docker-compose ps
Name Command State Ports
--------------------------------------------------------------------------------
devweek15code_elasticsearch_1 /bin/sh -c /opt/elasticsea ... Exit -1
devweek15code_postgres_1 /docker-entrypoint.sh postgres Exit 0
devweek15code_transfer_1 /bin/sh -c waitport elasti ... Exit 0
[ssmith] docker-compose rm —force
Going to remove devweek15code_transfer_1, devweek15code_elasticsearch_1, devweek15code_postgres_1
Removing devweek15code_postgres_1...
Removing devweek15code_elasticsearch_1...
Removing devweek15code_transfer_1…
[ssmith] docker-compose ps
Name Command State Ports
--------------------------------------------------------------------------------
[ssmith]
Discussion
Rafael Neff
Running With Bamboo
Plan
Stage
Job
Tasks
QA
Staging
Prod
Artifacts
Deployment
Environments
Git Repo
Bamboo Live
https://atlascamp2015.atlassian.net/
All New! Bamboo Docker Task!
AWS cloud agents with Docker
With Docker
Or create
your own
Require Docker support
Bamboo will start
on-demand
Building
Running
Linking
Compose with BambooSouth Florida
Classical Review
No Compose? No problem…
Running Compose
Cleaning up
Extracting ResultsAtlantic Sentinel
Fetching container files
[ssmith] docker-compose ps
Name Command State Ports
--------------------------------------------------------------------------------
devweek15code_elasticsearch_1 /bin/sh -c /opt/elasticsea ... Exit -1
devweek15code_postgres_1 /docker-entrypoint.sh postgres Exit 0
devweek15code_transfer_1 /bin/sh -c waitport elasti ... Exit 0
[ssmith] docker-compose ps -q transfer
fd7e728e3e9a361d96c253f5aeadab1a3506538d1b0e19d27c82848d9bf48bf8
[ssmith] ID=`docker-compose ps -q transfer`
[ssmith] docker cp $ID:/code/testreports.xml .
[ssmith] file testreports.xml
testreports.xml: XML document text
Fetching in Bamboo
Using JUnit Parser
Using JUnit results
Using JUnit results
Deployment Environments
Plan
Stage
Job
Tasks
QA
Staging
Prod
Artifacts
Deployment
Environments
Git Repo
Deployment Environments
QA
Staging
Prod
Artifacts
Deployment
Environments
Sharing Artifacts
Configuring the Environment
Configuring the Environment
Configuring the Environment
2
3
Useful Links
https://www.docker.com/subscribe_newsletter/
1 https://www.docker.com/
4 http://www.nkode.io/2014/08/24/valuable-docker-links.html
http://boot2docker.io/
Thank you!
STEVE SMITH • DEVOPS ADVOCATE • ATLASSIAN • @TARKASTEVE
Ad

More Related Content

What's hot (20)

Devops Boise - Israel Shirk - Pragmatic Migration to Infrastructure As Code
Devops Boise - Israel Shirk - Pragmatic Migration to Infrastructure As CodeDevops Boise - Israel Shirk - Pragmatic Migration to Infrastructure As Code
Devops Boise - Israel Shirk - Pragmatic Migration to Infrastructure As Code
Israel Shirk
 
How Docker simplifies CI/CD
How Docker simplifies CI/CDHow Docker simplifies CI/CD
How Docker simplifies CI/CD
Gabriel N. Schenker
 
Rise of the Machines - Automate your Development
Rise of the Machines - Automate your DevelopmentRise of the Machines - Automate your Development
Rise of the Machines - Automate your Development
Sven Peters
 
Using Multi-stage Docker, Go, Java,& Bazel to DESTROY Long Build Times
Using Multi-stage Docker, Go, Java,& Bazel to DESTROY Long Build TimesUsing Multi-stage Docker, Go, Java,& Bazel to DESTROY Long Build Times
Using Multi-stage Docker, Go, Java,& Bazel to DESTROY Long Build Times
DevOps.com
 
DevOps with Serverless
DevOps with ServerlessDevOps with Serverless
DevOps with Serverless
Yan Cui
 
Using Docker for Testing
Using Docker for TestingUsing Docker for Testing
Using Docker for Testing
Carlos Sanchez
 
Where is my scalable API?
Where is my scalable API?Where is my scalable API?
Where is my scalable API?
Juan Pablo Genovese
 
Kloud
KloudKloud
Kloud
Pankaj Kaushal
 
Drone CI - Container native continuous Integration / Delivery
Drone CI - Container native continuous Integration / DeliveryDrone CI - Container native continuous Integration / Delivery
Drone CI - Container native continuous Integration / Delivery
Patrick Jahns
 
Continuous Delivery Pipeline with Docker and Jenkins
Continuous Delivery Pipeline with Docker and JenkinsContinuous Delivery Pipeline with Docker and Jenkins
Continuous Delivery Pipeline with Docker and Jenkins
Camilo Ribeiro
 
Dev ops with smell v1.2
Dev ops with smell v1.2Dev ops with smell v1.2
Dev ops with smell v1.2
Antons Kranga
 
Enabling Hybrid Workflows with Docker/Mesos @Orbitz
Enabling Hybrid Workflows with Docker/Mesos @OrbitzEnabling Hybrid Workflows with Docker/Mesos @Orbitz
Enabling Hybrid Workflows with Docker/Mesos @Orbitz
Steve Hoffman
 
Automated Deployments with Ansible
Automated Deployments with AnsibleAutomated Deployments with Ansible
Automated Deployments with Ansible
Martin Etmajer
 
Testing with Docker
Testing with DockerTesting with Docker
Testing with Docker
toffermann
 
Serverless in production, an experience report (CoDe-Conf)
Serverless in production, an experience report (CoDe-Conf)Serverless in production, an experience report (CoDe-Conf)
Serverless in production, an experience report (CoDe-Conf)
Yan Cui
 
OpenWhisk
OpenWhiskOpenWhisk
OpenWhisk
Juan Pablo Genovese
 
FrenchKit 2017: Server(less) Swift
FrenchKit 2017: Server(less) SwiftFrenchKit 2017: Server(less) Swift
FrenchKit 2017: Server(less) Swift
Chris Bailey
 
Drone your Ansible
Drone your AnsibleDrone your Ansible
Drone your Ansible
Dennis Rowe
 
Concourse updates
Concourse updatesConcourse updates
Concourse updates
Gwenn Etourneau
 
Hooking Docker With Selenium
Hooking Docker With SeleniumHooking Docker With Selenium
Hooking Docker With Selenium
Sujith Vakathanam
 
Devops Boise - Israel Shirk - Pragmatic Migration to Infrastructure As Code
Devops Boise - Israel Shirk - Pragmatic Migration to Infrastructure As CodeDevops Boise - Israel Shirk - Pragmatic Migration to Infrastructure As Code
Devops Boise - Israel Shirk - Pragmatic Migration to Infrastructure As Code
Israel Shirk
 
Rise of the Machines - Automate your Development
Rise of the Machines - Automate your DevelopmentRise of the Machines - Automate your Development
Rise of the Machines - Automate your Development
Sven Peters
 
Using Multi-stage Docker, Go, Java,& Bazel to DESTROY Long Build Times
Using Multi-stage Docker, Go, Java,& Bazel to DESTROY Long Build TimesUsing Multi-stage Docker, Go, Java,& Bazel to DESTROY Long Build Times
Using Multi-stage Docker, Go, Java,& Bazel to DESTROY Long Build Times
DevOps.com
 
DevOps with Serverless
DevOps with ServerlessDevOps with Serverless
DevOps with Serverless
Yan Cui
 
Using Docker for Testing
Using Docker for TestingUsing Docker for Testing
Using Docker for Testing
Carlos Sanchez
 
Drone CI - Container native continuous Integration / Delivery
Drone CI - Container native continuous Integration / DeliveryDrone CI - Container native continuous Integration / Delivery
Drone CI - Container native continuous Integration / Delivery
Patrick Jahns
 
Continuous Delivery Pipeline with Docker and Jenkins
Continuous Delivery Pipeline with Docker and JenkinsContinuous Delivery Pipeline with Docker and Jenkins
Continuous Delivery Pipeline with Docker and Jenkins
Camilo Ribeiro
 
Dev ops with smell v1.2
Dev ops with smell v1.2Dev ops with smell v1.2
Dev ops with smell v1.2
Antons Kranga
 
Enabling Hybrid Workflows with Docker/Mesos @Orbitz
Enabling Hybrid Workflows with Docker/Mesos @OrbitzEnabling Hybrid Workflows with Docker/Mesos @Orbitz
Enabling Hybrid Workflows with Docker/Mesos @Orbitz
Steve Hoffman
 
Automated Deployments with Ansible
Automated Deployments with AnsibleAutomated Deployments with Ansible
Automated Deployments with Ansible
Martin Etmajer
 
Testing with Docker
Testing with DockerTesting with Docker
Testing with Docker
toffermann
 
Serverless in production, an experience report (CoDe-Conf)
Serverless in production, an experience report (CoDe-Conf)Serverless in production, an experience report (CoDe-Conf)
Serverless in production, an experience report (CoDe-Conf)
Yan Cui
 
FrenchKit 2017: Server(less) Swift
FrenchKit 2017: Server(less) SwiftFrenchKit 2017: Server(less) Swift
FrenchKit 2017: Server(less) Swift
Chris Bailey
 
Drone your Ansible
Drone your AnsibleDrone your Ansible
Drone your Ansible
Dennis Rowe
 
Hooking Docker With Selenium
Hooking Docker With SeleniumHooking Docker With Selenium
Hooking Docker With Selenium
Sujith Vakathanam
 

Viewers also liked (6)

LCE13: Overview of Linaro Project Management Methodology
LCE13: Overview of Linaro Project Management MethodologyLCE13: Overview of Linaro Project Management Methodology
LCE13: Overview of Linaro Project Management Methodology
Linaro
 
Practical Continuous Deployment, Devoxx UK 2015
Practical Continuous Deployment, Devoxx UK 2015Practical Continuous Deployment, Devoxx UK 2015
Practical Continuous Deployment, Devoxx UK 2015
Steve Smith
 
DeveloperWeek 2015: A Practical Introduction to Docker
DeveloperWeek 2015: A Practical Introduction to DockerDeveloperWeek 2015: A Practical Introduction to Docker
DeveloperWeek 2015: A Practical Introduction to Docker
Steve Smith
 
Continuous talk, AnsibleFest London 2016
Continuous talk, AnsibleFest London 2016Continuous talk, AnsibleFest London 2016
Continuous talk, AnsibleFest London 2016
Steve Smith
 
Understanding git: Voxxed Vienna 2016
Understanding git: Voxxed Vienna 2016Understanding git: Voxxed Vienna 2016
Understanding git: Voxxed Vienna 2016
Steve Smith
 
How Atlassian's Build Engineering Team Has Scaled to 150k Builds Per Month an...
How Atlassian's Build Engineering Team Has Scaled to 150k Builds Per Month an...How Atlassian's Build Engineering Team Has Scaled to 150k Builds Per Month an...
How Atlassian's Build Engineering Team Has Scaled to 150k Builds Per Month an...
Peter Leschev
 
LCE13: Overview of Linaro Project Management Methodology
LCE13: Overview of Linaro Project Management MethodologyLCE13: Overview of Linaro Project Management Methodology
LCE13: Overview of Linaro Project Management Methodology
Linaro
 
Practical Continuous Deployment, Devoxx UK 2015
Practical Continuous Deployment, Devoxx UK 2015Practical Continuous Deployment, Devoxx UK 2015
Practical Continuous Deployment, Devoxx UK 2015
Steve Smith
 
DeveloperWeek 2015: A Practical Introduction to Docker
DeveloperWeek 2015: A Practical Introduction to DockerDeveloperWeek 2015: A Practical Introduction to Docker
DeveloperWeek 2015: A Practical Introduction to Docker
Steve Smith
 
Continuous talk, AnsibleFest London 2016
Continuous talk, AnsibleFest London 2016Continuous talk, AnsibleFest London 2016
Continuous talk, AnsibleFest London 2016
Steve Smith
 
Understanding git: Voxxed Vienna 2016
Understanding git: Voxxed Vienna 2016Understanding git: Voxxed Vienna 2016
Understanding git: Voxxed Vienna 2016
Steve Smith
 
How Atlassian's Build Engineering Team Has Scaled to 150k Builds Per Month an...
How Atlassian's Build Engineering Team Has Scaled to 150k Builds Per Month an...How Atlassian's Build Engineering Team Has Scaled to 150k Builds Per Month an...
How Atlassian's Build Engineering Team Has Scaled to 150k Builds Per Month an...
Peter Leschev
 
Ad

Similar to AtlasCamp 2015 Docker continuous integration training (20)

Docker command
Docker commandDocker command
Docker command
Eric Ahn
 
Docker: ao vivo e a cores
Docker: ao vivo e a coresDocker: ao vivo e a cores
Docker: ao vivo e a cores
Pedro Arthur Duarte
 
Check the version with fixes. Link in description
Check the version with fixes. Link in descriptionCheck the version with fixes. Link in description
Check the version with fixes. Link in description
Przemyslaw Koltermann
 
Using Nix and Docker as automated deployment solutions
Using Nix and Docker as automated deployment solutionsUsing Nix and Docker as automated deployment solutions
Using Nix and Docker as automated deployment solutions
Sander van der Burg
 
Docker as an every day work tool
Docker as an every day work toolDocker as an every day work tool
Docker as an every day work tool
Przemyslaw Koltermann
 
DCEU 18: Tips and Tricks of the Docker Captains
DCEU 18: Tips and Tricks of the Docker CaptainsDCEU 18: Tips and Tricks of the Docker Captains
DCEU 18: Tips and Tricks of the Docker Captains
Docker, Inc.
 
Docker practice
Docker practiceDocker practice
Docker practice
wonyong hwang
 
Использование Docker в CI / Александр Акбашев (HERE Technologies)
Использование Docker в CI / Александр Акбашев (HERE Technologies)Использование Docker в CI / Александр Акбашев (HERE Technologies)
Использование Docker в CI / Александр Акбашев (HERE Technologies)
Ontico
 
AWS와 Docker Swarm을 이용한 쉽고 빠른 컨테이너 오케스트레이션 - AWS Summit Seoul 2017
AWS와 Docker Swarm을 이용한 쉽고 빠른 컨테이너 오케스트레이션 - AWS Summit Seoul 2017AWS와 Docker Swarm을 이용한 쉽고 빠른 컨테이너 오케스트레이션 - AWS Summit Seoul 2017
AWS와 Docker Swarm을 이용한 쉽고 빠른 컨테이너 오케스트레이션 - AWS Summit Seoul 2017
Amazon Web Services Korea
 
Docker Demo @ IuK Seminar
Docker Demo @ IuK SeminarDocker Demo @ IuK Seminar
Docker Demo @ IuK Seminar
Martin Scharm
 
Dockerize everything TopConf Tallinn
Dockerize everything TopConf TallinnDockerize everything TopConf Tallinn
Dockerize everything TopConf Tallinn
Thomas Einwaller
 
Scaling Development Environments with Docker
Scaling Development Environments with DockerScaling Development Environments with Docker
Scaling Development Environments with Docker
Docker, Inc.
 
Running Docker in Development & Production (#ndcoslo 2015)
Running Docker in Development & Production (#ndcoslo 2015)Running Docker in Development & Production (#ndcoslo 2015)
Running Docker in Development & Production (#ndcoslo 2015)
Ben Hall
 
Real World Experience of Running Docker in Development and Production
Real World Experience of Running Docker in Development and ProductionReal World Experience of Running Docker in Development and Production
Real World Experience of Running Docker in Development and Production
Ben Hall
 
Docker and friends at Linux Days 2014 in Prague
Docker and friends at Linux Days 2014 in PragueDocker and friends at Linux Days 2014 in Prague
Docker and friends at Linux Days 2014 in Prague
tomasbart
 
Chris Swan ONUG Academy - Container Networks Tutorial
Chris Swan ONUG Academy - Container Networks TutorialChris Swan ONUG Academy - Container Networks Tutorial
Chris Swan ONUG Academy - Container Networks Tutorial
Cohesive Networks
 
vBACD - Introduction to Opscode Chef - 2/29
vBACD - Introduction to Opscode Chef - 2/29vBACD - Introduction to Opscode Chef - 2/29
vBACD - Introduction to Opscode Chef - 2/29
CloudStack - Open Source Cloud Computing Project
 
Docker Registry + Basic Auth
Docker Registry + Basic AuthDocker Registry + Basic Auth
Docker Registry + Basic Auth
Remotty
 
Docker, the Future of DevOps
Docker, the Future of DevOpsDocker, the Future of DevOps
Docker, the Future of DevOps
andersjanmyr
 
Docker orchestration v4
Docker orchestration v4Docker orchestration v4
Docker orchestration v4
Hojin Kim
 
Docker command
Docker commandDocker command
Docker command
Eric Ahn
 
Check the version with fixes. Link in description
Check the version with fixes. Link in descriptionCheck the version with fixes. Link in description
Check the version with fixes. Link in description
Przemyslaw Koltermann
 
Using Nix and Docker as automated deployment solutions
Using Nix and Docker as automated deployment solutionsUsing Nix and Docker as automated deployment solutions
Using Nix and Docker as automated deployment solutions
Sander van der Burg
 
DCEU 18: Tips and Tricks of the Docker Captains
DCEU 18: Tips and Tricks of the Docker CaptainsDCEU 18: Tips and Tricks of the Docker Captains
DCEU 18: Tips and Tricks of the Docker Captains
Docker, Inc.
 
Использование Docker в CI / Александр Акбашев (HERE Technologies)
Использование Docker в CI / Александр Акбашев (HERE Technologies)Использование Docker в CI / Александр Акбашев (HERE Technologies)
Использование Docker в CI / Александр Акбашев (HERE Technologies)
Ontico
 
AWS와 Docker Swarm을 이용한 쉽고 빠른 컨테이너 오케스트레이션 - AWS Summit Seoul 2017
AWS와 Docker Swarm을 이용한 쉽고 빠른 컨테이너 오케스트레이션 - AWS Summit Seoul 2017AWS와 Docker Swarm을 이용한 쉽고 빠른 컨테이너 오케스트레이션 - AWS Summit Seoul 2017
AWS와 Docker Swarm을 이용한 쉽고 빠른 컨테이너 오케스트레이션 - AWS Summit Seoul 2017
Amazon Web Services Korea
 
Docker Demo @ IuK Seminar
Docker Demo @ IuK SeminarDocker Demo @ IuK Seminar
Docker Demo @ IuK Seminar
Martin Scharm
 
Dockerize everything TopConf Tallinn
Dockerize everything TopConf TallinnDockerize everything TopConf Tallinn
Dockerize everything TopConf Tallinn
Thomas Einwaller
 
Scaling Development Environments with Docker
Scaling Development Environments with DockerScaling Development Environments with Docker
Scaling Development Environments with Docker
Docker, Inc.
 
Running Docker in Development & Production (#ndcoslo 2015)
Running Docker in Development & Production (#ndcoslo 2015)Running Docker in Development & Production (#ndcoslo 2015)
Running Docker in Development & Production (#ndcoslo 2015)
Ben Hall
 
Real World Experience of Running Docker in Development and Production
Real World Experience of Running Docker in Development and ProductionReal World Experience of Running Docker in Development and Production
Real World Experience of Running Docker in Development and Production
Ben Hall
 
Docker and friends at Linux Days 2014 in Prague
Docker and friends at Linux Days 2014 in PragueDocker and friends at Linux Days 2014 in Prague
Docker and friends at Linux Days 2014 in Prague
tomasbart
 
Chris Swan ONUG Academy - Container Networks Tutorial
Chris Swan ONUG Academy - Container Networks TutorialChris Swan ONUG Academy - Container Networks Tutorial
Chris Swan ONUG Academy - Container Networks Tutorial
Cohesive Networks
 
Docker Registry + Basic Auth
Docker Registry + Basic AuthDocker Registry + Basic Auth
Docker Registry + Basic Auth
Remotty
 
Docker, the Future of DevOps
Docker, the Future of DevOpsDocker, the Future of DevOps
Docker, the Future of DevOps
andersjanmyr
 
Docker orchestration v4
Docker orchestration v4Docker orchestration v4
Docker orchestration v4
Hojin Kim
 
Ad

More from Steve Smith (10)

Knowledge is Power: Getting out of trouble by understanding Git
Knowledge is Power: Getting out of trouble by understanding GitKnowledge is Power: Getting out of trouble by understanding Git
Knowledge is Power: Getting out of trouble by understanding Git
Steve Smith
 
Understanding Git - GOTO London 2015
Understanding Git - GOTO London 2015Understanding Git - GOTO London 2015
Understanding Git - GOTO London 2015
Steve Smith
 
London Atlassian User Group - February 2014
London Atlassian User Group - February 2014London Atlassian User Group - February 2014
London Atlassian User Group - February 2014
Steve Smith
 
Accessgrid XMPP rationale
Accessgrid XMPP rationaleAccessgrid XMPP rationale
Accessgrid XMPP rationale
Steve Smith
 
Accessgrid XMPP implementation
Accessgrid XMPP implementationAccessgrid XMPP implementation
Accessgrid XMPP implementation
Steve Smith
 
Vislab presentation
Vislab presentationVislab presentation
Vislab presentation
Steve Smith
 
APAC-05 XMPP AccessGrid presentation
APAC-05 XMPP AccessGrid presentationAPAC-05 XMPP AccessGrid presentation
APAC-05 XMPP AccessGrid presentation
Steve Smith
 
Sydgraph presentation 2004
Sydgraph presentation 2004Sydgraph presentation 2004
Sydgraph presentation 2004
Steve Smith
 
Devops London 2013 - Opening the inner circle
Devops London 2013 - Opening the inner circleDevops London 2013 - Opening the inner circle
Devops London 2013 - Opening the inner circle
Steve Smith
 
Devops London 2013 - Robust systems or, not fucking the customer
Devops London 2013 - Robust systems or, not fucking the customerDevops London 2013 - Robust systems or, not fucking the customer
Devops London 2013 - Robust systems or, not fucking the customer
Steve Smith
 
Knowledge is Power: Getting out of trouble by understanding Git
Knowledge is Power: Getting out of trouble by understanding GitKnowledge is Power: Getting out of trouble by understanding Git
Knowledge is Power: Getting out of trouble by understanding Git
Steve Smith
 
Understanding Git - GOTO London 2015
Understanding Git - GOTO London 2015Understanding Git - GOTO London 2015
Understanding Git - GOTO London 2015
Steve Smith
 
London Atlassian User Group - February 2014
London Atlassian User Group - February 2014London Atlassian User Group - February 2014
London Atlassian User Group - February 2014
Steve Smith
 
Accessgrid XMPP rationale
Accessgrid XMPP rationaleAccessgrid XMPP rationale
Accessgrid XMPP rationale
Steve Smith
 
Accessgrid XMPP implementation
Accessgrid XMPP implementationAccessgrid XMPP implementation
Accessgrid XMPP implementation
Steve Smith
 
Vislab presentation
Vislab presentationVislab presentation
Vislab presentation
Steve Smith
 
APAC-05 XMPP AccessGrid presentation
APAC-05 XMPP AccessGrid presentationAPAC-05 XMPP AccessGrid presentation
APAC-05 XMPP AccessGrid presentation
Steve Smith
 
Sydgraph presentation 2004
Sydgraph presentation 2004Sydgraph presentation 2004
Sydgraph presentation 2004
Steve Smith
 
Devops London 2013 - Opening the inner circle
Devops London 2013 - Opening the inner circleDevops London 2013 - Opening the inner circle
Devops London 2013 - Opening the inner circle
Steve Smith
 
Devops London 2013 - Robust systems or, not fucking the customer
Devops London 2013 - Robust systems or, not fucking the customerDevops London 2013 - Robust systems or, not fucking the customer
Devops London 2013 - Robust systems or, not fucking the customer
Steve Smith
 

Recently uploaded (20)

Linux Support for SMARC: How Toradex Empowers Embedded Developers
Linux Support for SMARC: How Toradex Empowers Embedded DevelopersLinux Support for SMARC: How Toradex Empowers Embedded Developers
Linux Support for SMARC: How Toradex Empowers Embedded Developers
Toradex
 
How analogue intelligence complements AI
How analogue intelligence complements AIHow analogue intelligence complements AI
How analogue intelligence complements AI
Paul Rowe
 
How Can I use the AI Hype in my Business Context?
How Can I use the AI Hype in my Business Context?How Can I use the AI Hype in my Business Context?
How Can I use the AI Hype in my Business Context?
Daniel Lehner
 
The Evolution of Meme Coins A New Era for Digital Currency ppt.pdf
The Evolution of Meme Coins A New Era for Digital Currency ppt.pdfThe Evolution of Meme Coins A New Era for Digital Currency ppt.pdf
The Evolution of Meme Coins A New Era for Digital Currency ppt.pdf
Abi john
 
IEDM 2024 Tutorial2_Advances in CMOS Technologies and Future Directions for C...
IEDM 2024 Tutorial2_Advances in CMOS Technologies and Future Directions for C...IEDM 2024 Tutorial2_Advances in CMOS Technologies and Future Directions for C...
IEDM 2024 Tutorial2_Advances in CMOS Technologies and Future Directions for C...
organizerofv
 
Technology Trends in 2025: AI and Big Data Analytics
Technology Trends in 2025: AI and Big Data AnalyticsTechnology Trends in 2025: AI and Big Data Analytics
Technology Trends in 2025: AI and Big Data Analytics
InData Labs
 
TrustArc Webinar: Consumer Expectations vs Corporate Realities on Data Broker...
TrustArc Webinar: Consumer Expectations vs Corporate Realities on Data Broker...TrustArc Webinar: Consumer Expectations vs Corporate Realities on Data Broker...
TrustArc Webinar: Consumer Expectations vs Corporate Realities on Data Broker...
TrustArc
 
SAP Modernization: Maximizing the Value of Your SAP S/4HANA Migration.pdf
SAP Modernization: Maximizing the Value of Your SAP S/4HANA Migration.pdfSAP Modernization: Maximizing the Value of Your SAP S/4HANA Migration.pdf
SAP Modernization: Maximizing the Value of Your SAP S/4HANA Migration.pdf
Precisely
 
AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...
AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...
AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...
Alan Dix
 
Mobile App Development Company in Saudi Arabia
Mobile App Development Company in Saudi ArabiaMobile App Development Company in Saudi Arabia
Mobile App Development Company in Saudi Arabia
Steve Jonas
 
AI EngineHost Review: Revolutionary USA Datacenter-Based Hosting with NVIDIA ...
AI EngineHost Review: Revolutionary USA Datacenter-Based Hosting with NVIDIA ...AI EngineHost Review: Revolutionary USA Datacenter-Based Hosting with NVIDIA ...
AI EngineHost Review: Revolutionary USA Datacenter-Based Hosting with NVIDIA ...
SOFTTECHHUB
 
Noah Loul Shares 5 Steps to Implement AI Agents for Maximum Business Efficien...
Noah Loul Shares 5 Steps to Implement AI Agents for Maximum Business Efficien...Noah Loul Shares 5 Steps to Implement AI Agents for Maximum Business Efficien...
Noah Loul Shares 5 Steps to Implement AI Agents for Maximum Business Efficien...
Noah Loul
 
Build Your Own Copilot & Agents For Devs
Build Your Own Copilot & Agents For DevsBuild Your Own Copilot & Agents For Devs
Build Your Own Copilot & Agents For Devs
Brian McKeiver
 
Increasing Retail Store Efficiency How can Planograms Save Time and Money.pptx
Increasing Retail Store Efficiency How can Planograms Save Time and Money.pptxIncreasing Retail Store Efficiency How can Planograms Save Time and Money.pptx
Increasing Retail Store Efficiency How can Planograms Save Time and Money.pptx
Anoop Ashok
 
#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025
#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025
#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025
BookNet Canada
 
HCL Nomad Web – Best Practices und Verwaltung von Multiuser-Umgebungen
HCL Nomad Web – Best Practices und Verwaltung von Multiuser-UmgebungenHCL Nomad Web – Best Practices und Verwaltung von Multiuser-Umgebungen
HCL Nomad Web – Best Practices und Verwaltung von Multiuser-Umgebungen
panagenda
 
Heap, Types of Heap, Insertion and Deletion
Heap, Types of Heap, Insertion and DeletionHeap, Types of Heap, Insertion and Deletion
Heap, Types of Heap, Insertion and Deletion
Jaydeep Kale
 
Massive Power Outage Hits Spain, Portugal, and France: Causes, Impact, and On...
Massive Power Outage Hits Spain, Portugal, and France: Causes, Impact, and On...Massive Power Outage Hits Spain, Portugal, and France: Causes, Impact, and On...
Massive Power Outage Hits Spain, Portugal, and France: Causes, Impact, and On...
Aqusag Technologies
 
Cyber Awareness overview for 2025 month of security
Cyber Awareness overview for 2025 month of securityCyber Awareness overview for 2025 month of security
Cyber Awareness overview for 2025 month of security
riccardosl1
 
tecnologias de las primeras civilizaciones.pdf
tecnologias de las primeras civilizaciones.pdftecnologias de las primeras civilizaciones.pdf
tecnologias de las primeras civilizaciones.pdf
fjgm517
 
Linux Support for SMARC: How Toradex Empowers Embedded Developers
Linux Support for SMARC: How Toradex Empowers Embedded DevelopersLinux Support for SMARC: How Toradex Empowers Embedded Developers
Linux Support for SMARC: How Toradex Empowers Embedded Developers
Toradex
 
How analogue intelligence complements AI
How analogue intelligence complements AIHow analogue intelligence complements AI
How analogue intelligence complements AI
Paul Rowe
 
How Can I use the AI Hype in my Business Context?
How Can I use the AI Hype in my Business Context?How Can I use the AI Hype in my Business Context?
How Can I use the AI Hype in my Business Context?
Daniel Lehner
 
The Evolution of Meme Coins A New Era for Digital Currency ppt.pdf
The Evolution of Meme Coins A New Era for Digital Currency ppt.pdfThe Evolution of Meme Coins A New Era for Digital Currency ppt.pdf
The Evolution of Meme Coins A New Era for Digital Currency ppt.pdf
Abi john
 
IEDM 2024 Tutorial2_Advances in CMOS Technologies and Future Directions for C...
IEDM 2024 Tutorial2_Advances in CMOS Technologies and Future Directions for C...IEDM 2024 Tutorial2_Advances in CMOS Technologies and Future Directions for C...
IEDM 2024 Tutorial2_Advances in CMOS Technologies and Future Directions for C...
organizerofv
 
Technology Trends in 2025: AI and Big Data Analytics
Technology Trends in 2025: AI and Big Data AnalyticsTechnology Trends in 2025: AI and Big Data Analytics
Technology Trends in 2025: AI and Big Data Analytics
InData Labs
 
TrustArc Webinar: Consumer Expectations vs Corporate Realities on Data Broker...
TrustArc Webinar: Consumer Expectations vs Corporate Realities on Data Broker...TrustArc Webinar: Consumer Expectations vs Corporate Realities on Data Broker...
TrustArc Webinar: Consumer Expectations vs Corporate Realities on Data Broker...
TrustArc
 
SAP Modernization: Maximizing the Value of Your SAP S/4HANA Migration.pdf
SAP Modernization: Maximizing the Value of Your SAP S/4HANA Migration.pdfSAP Modernization: Maximizing the Value of Your SAP S/4HANA Migration.pdf
SAP Modernization: Maximizing the Value of Your SAP S/4HANA Migration.pdf
Precisely
 
AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...
AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...
AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...
Alan Dix
 
Mobile App Development Company in Saudi Arabia
Mobile App Development Company in Saudi ArabiaMobile App Development Company in Saudi Arabia
Mobile App Development Company in Saudi Arabia
Steve Jonas
 
AI EngineHost Review: Revolutionary USA Datacenter-Based Hosting with NVIDIA ...
AI EngineHost Review: Revolutionary USA Datacenter-Based Hosting with NVIDIA ...AI EngineHost Review: Revolutionary USA Datacenter-Based Hosting with NVIDIA ...
AI EngineHost Review: Revolutionary USA Datacenter-Based Hosting with NVIDIA ...
SOFTTECHHUB
 
Noah Loul Shares 5 Steps to Implement AI Agents for Maximum Business Efficien...
Noah Loul Shares 5 Steps to Implement AI Agents for Maximum Business Efficien...Noah Loul Shares 5 Steps to Implement AI Agents for Maximum Business Efficien...
Noah Loul Shares 5 Steps to Implement AI Agents for Maximum Business Efficien...
Noah Loul
 
Build Your Own Copilot & Agents For Devs
Build Your Own Copilot & Agents For DevsBuild Your Own Copilot & Agents For Devs
Build Your Own Copilot & Agents For Devs
Brian McKeiver
 
Increasing Retail Store Efficiency How can Planograms Save Time and Money.pptx
Increasing Retail Store Efficiency How can Planograms Save Time and Money.pptxIncreasing Retail Store Efficiency How can Planograms Save Time and Money.pptx
Increasing Retail Store Efficiency How can Planograms Save Time and Money.pptx
Anoop Ashok
 
#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025
#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025
#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025
BookNet Canada
 
HCL Nomad Web – Best Practices und Verwaltung von Multiuser-Umgebungen
HCL Nomad Web – Best Practices und Verwaltung von Multiuser-UmgebungenHCL Nomad Web – Best Practices und Verwaltung von Multiuser-Umgebungen
HCL Nomad Web – Best Practices und Verwaltung von Multiuser-Umgebungen
panagenda
 
Heap, Types of Heap, Insertion and Deletion
Heap, Types of Heap, Insertion and DeletionHeap, Types of Heap, Insertion and Deletion
Heap, Types of Heap, Insertion and Deletion
Jaydeep Kale
 
Massive Power Outage Hits Spain, Portugal, and France: Causes, Impact, and On...
Massive Power Outage Hits Spain, Portugal, and France: Causes, Impact, and On...Massive Power Outage Hits Spain, Portugal, and France: Causes, Impact, and On...
Massive Power Outage Hits Spain, Portugal, and France: Causes, Impact, and On...
Aqusag Technologies
 
Cyber Awareness overview for 2025 month of security
Cyber Awareness overview for 2025 month of securityCyber Awareness overview for 2025 month of security
Cyber Awareness overview for 2025 month of security
riccardosl1
 
tecnologias de las primeras civilizaciones.pdf
tecnologias de las primeras civilizaciones.pdftecnologias de las primeras civilizaciones.pdf
tecnologias de las primeras civilizaciones.pdf
fjgm517
 

AtlasCamp 2015 Docker continuous integration training

  • 1. Continuous Integration with Docker and Bamboo STEVE SMITH • DEVOPS ADVOCATE • ATLASSIAN • @TARKASTEVE https://bitbucket.org/ssmith/atlascamp2015-docker-ci
  • 5. Virtual Machine Virtual HW BIOS/EFI Guest FS / Kernel Applications Physical Hardware Host FS / Kernel VM Hypervisor BIOS/EFI Virtual HW BIOS/EFI Guest FS / Kernel Applications
  • 6. Containers / Docker Physical Hardware Host FS / Kernel Docker Engine BIOS/EFI Guest FS Application Guest FS Application Virtual HW BIOS/EFI Guest FS / Kernel Applications Physical Hardware Host FS / Kernel VM Hypervisor BIOS/EFI Virtual HW BIOS/EFI Guest FS / Kernel Applications
  • 7. Using features of the Linux kernel Docker libcontainer systemd nspawn libvirt cgroups CPU accounting Namespaces Posix capabilities btrfs OverlayFS LXC
  • 9. Containers take this further… Network Abstraction Process Isolation Filesystem Isolation Resource Limits
  • 10. Docker takes this to the next level… Build Tools Packaging Lifecycle Communication Dev (boot2docker) Sharing
  • 11. boot2docker Virtual Hardware Host FS / Kernel BIOS/EFI Guest FS Application Guest FS Application
  • 14. Docker containers are like OO classes… Inheritance Sourcefile (Dockerfile) Compile Dep. Injection Declarative Deps
  • 15. FROM ubuntu:trusty RUN apt-get update && apt-get install -y nginx && apt-get clean EXPOSE 80 EXPOSE 443 CMD nginx -g daemon off; Single inheritance Add member Override parent behaviour Exposed linking points Dockerfile ~= Sourcefile
  • 16. Inheritance resolved at runtime Ubuntu Add nginx Add run command (sorta like JVM class assembly) Union Filesystem - AUFS - BTRFS - Devicemapper - OverlayFS
  • 17. ‘run’ instantiates a new container Ubuntu Add nginx Add run command Writable Immutable (kinda like ‘new’) Runtime layer
  • 18. [ssmith] $ docker build -q --tag=mynginx docker/mynginx/ Sending build context to Docker daemon 12.72 MB Sending build context to Docker daemon Step 0 : FROM ubuntu:trusty ---> 8eaa4ff06b53 Step 1 : RUN apt-get update && apt-get install -y nginx && apt-get clea ---> Running in f05a4a034fe3 ---> 1e84ac75dd9a Removing intermediate container f05a4a034fe3 Step 2 : EXPOSE 80 ---> Running in 77602b8eb9ec ---> 4076f56233ff Removing intermediate container 77602b8eb9ec Step 3 : EXPOSE 443 ---> Running in b627b8c1d328 ---> f5a3ff140964 Removing intermediate container b627b8c1d328 Step 4 : CMD nginx -g daemon off; ---> Running in 132573fe4fc9 ---> c1df0408cf70 ‘build’ compiles to binary
  • 19. Inspecting the stack [ssmith] $ docker history mynginx IMAGE CREATED CREATED BY 606f0f611cb2 6 days ago /bin/sh -c #(nop) CMD [nginx -g daemon off;] 27d0fad8620d 6 days ago /bin/sh -c #(nop) EXPOSE map[443/tcp:{}] dc26b50e9806 6 days ago /bin/sh -c #(nop) EXPOSE map[80/tcp:{}] 7a04b014a0a7 6 days ago /bin/sh -c apt-get update && apt-get install b39b81afc8ca 9 days ago /bin/sh -c #(nop) CMD [/bin/bash] 615c102e2290 9 days ago /bin/sh -c sed -i 's/^#s*(deb.*universe)$/ 837339b91538 9 days ago /bin/sh -c echo '#!/bin/sh' > /usr/sbin/polic 53f858aaaf03 9 days ago /bin/sh -c #(nop) ADD file:ca5b63647c6b7a419e 511136ea3c5a 19 months ago
  • 20. Linked Containers (dependency injection; sort-of…) Docker host postgresql client --link postgresql:pg can refer to hostname pg in commands
  • 25. The example project Transfer Trigger / Async Data Data (See http://bit.do/postgres-es for details)
  • 27. Docker testing Reuse images Startup speed Idempotent tests Dev / Test match Deploy to Docker
  • 29. Elasticsearch Dockerfile FROM java:openjdk-7-jre ENV ES_VER 1.3.4 ENV ES_URL https://download.elasticsearch.org/elasticsearch/elasticsearch/ elasticsearch-${ES_VER}.tar.gz WORKDIR /opt/ RUN adduser --system elasticsearch RUN curl ${ES_URL} -o elasticsearch.tgz && tar xzf elasticsearch.tgz && ln -s elasticsearch-${ES_VER} elasticsearch && mkdir /opt/elasticsearch/data/ && chown elasticsearch /opt/elasticsearch/data/ && mkdir /opt/elasticsearch/logs/ && chown elasticsearch /opt/elasticsearch/logs/ && rm elasticsearch.tgz EXPOSE 9200 EXPOSE 9300 USER elasticsearch CMD /opt/elasticsearch/bin/elasticsearch -f
  • 30. Elasticsearch build [ssmith] docker build -q --tag=elasticsearch docker/elasticsearch/ Sending build context to Docker daemon 2.56 kB Sending build context to Docker daemon Step 0 : FROM java:openjdk-7-jre ---> b797b3ba124d Step 1 : ENV ES_VER 1.3.4 ---> Running in 4842001c48d0 ---> 2717f23208b7 Removing intermediate container 4842001c48d0 Step 2 : ENV ES_URL https://download.elasticsearch.org/elasticsearch/elasticsearch/ elasticsearch-${ES_VER}.tar.gz ---> Running in b2f574153a18 ---> a292b608b854 Removing intermediate container b2f574153a18 Step 3 : WORKDIR /opt/ ---> Running in 0f138382e071 ---> aa2ebf2e8061 Removing intermediate container 0f138382e071 Step 4 : RUN adduser --system elasticsearch ---> Running in 0800878ae8c0 ---> 2b0c2619f328 Removing intermediate container 0800878ae8c0 Step 5 : RUN curl ${ES_URL} -o elasticsearch.tgz && tar xzf elasticsearch.tgz && ln -s elasticsearch-${ES_VER} elasticsearch && mkdir /opt/elasticsearch/data/ && chown elasticsearch /opt/elasticsearch/data/ && mkdir /opt/elasticsearch/logs/ &&
  • 31. Postgresql Dockerfile FROM postgres:9.2 ENV POSTGRES_USER customer COPY testschema.sql / COPY init-test-db.sh /docker-entrypoint-initdb.d/
  • 32. Postgresql init file #!/bin/bash echo "#### Create test DB ####" gosu postgres postgres --single <<EOF CREATE USER customer PASSWORD 'customer'; CREATE DATABASE customer OWNER customer; GRANT ALL PRIVILEGES ON DATABASE customer TO customer; EOF echo "#### Initialise test DB ####" gosu postgres postgres --single customer -j < /testschema.sql echo echo "#### Test DB initialised ####"
  • 33. Postgresql build [ssmith] docker build -q --tag=postgres docker/postgres/ Sending build context to Docker daemon 5.12 kB Sending build context to Docker daemon Step 0 : FROM postgres:9.2 ---> 898ba6de4072 Step 1 : ENV POSTGRES_USER customer ---> Running in 932957e34d5e ---> 91b679d67fd9 Removing intermediate container 932957e34d5e Step 2 : COPY testschema.sql / ---> 65b67419fe54 Removing intermediate container 54298baaa088 Step 3 : COPY init-test-db.sh /docker-entrypoint-initdb.d/ ---> b6d84236c1f7 Removing intermediate container f9000db9da92 Successfully built b6d84236c1f7
  • 34. Transfer Dockerfile FROM java:openjdk-7-jre # Install netcat for waitport RUN apt-get update && apt-get install -y netcat-openbsd && apt-get clean COPY docker/waitport /usr/local/bin/ RUN curl https://raw.githubusercontent.com/technomancy/leiningen/stable/bin/lein -o / usr/local/bin/lein && chmod a+rx /usr/local/bin/lein RUN adduser --disabled-password --gecos '' transfer ADD . /code RUN chown -R transfer.transfer /code USER transfer WORKDIR /code RUN lein deps CMD waitport elasticsearch 9200 && waitport postgres 5432 && lein test-out junit
  • 36. Manual run [ssmith] docker run -d —name=postgres postgres 181470ed78836c9285664c18f0d5b4c6a9069d28c4f71b9d621d4c24762ad938 [ssmith] docker run -d --name=elasticsearch elasticsearch 5718e1ba9b7caf0e25f53d803a128d2a3d4d518ae8d747b843cc2cbdd78620ce [smith] docker run --link postgres:postgres --link elasticsearch:elasticsearch transfer Waiting for TCP connection to elasticsearch:9200...OK Waiting for TCP connection to postgres:5432...OK Received notification for accountupdate for 55d3290b-5baa-4ca6-b353-cacf5b104c60 Performing update of 55d3290b-5baa-4ca6-b353-cacf5b104c60 Indexing row 55d3290b-5baa-4ca6-b353-cacf5b104c60 Mr. 55d3290b 55d3290b Esq. Dispatch complete
  • 37. Manual cleanup [ssmith] docker ps CONTAINER ID IMAGE COMMAND CREATED … 5718e1ba9b7c elasticsearch:latest "/bin/sh -c '/opt/el 5 minutes ago … 181470ed7883 postgres:latest "/docker-entrypoint. 6 minutes ago … [ssmith] docker kill elasticsearch postgres elasticsearch postgres [ssmith] docker ps CONTAINER ID IMAGE COMMAND CREATED … [ssmith] docker ps -a CONTAINER ID IMAGE COMMAND CREATED ff6e5409d8ba transfer:latest "/bin/sh -c 'waitpor 11 minutes ago 5718e1ba9b7c elasticsearch:latest "/bin/sh -c '/opt/el 11 minutes ago 181470ed7883 postgres:latest "/docker-entrypoint. 11 minutes ago [smith] docker rm transfer postgres elasticsearch transfer postgres elasticsearch
  • 40. Compose Declarative Deps Fetch Images Build Images Link Containers
  • 41. Our docker-compose.yml transfer: build: . links: - postgres - elasticsearch postgres: build: docker/postgres elasticsearch: build: docker/elasticsearch
  • 42. Compose Run [ssmith] docker-compose up Creating devweek15code_postgres_1... Creating devweek15code_elasticsearch_1... Creating devweek15code_transfer_1... Attaching to devweek15code_postgres_1, devweek15code_elasticsearch_1, devweek15code_transfer_1 postgres_1 | The files belonging to this database system will be owned by user "postgres". postgres_1 | This user must also own the server process. <SNIP> <SNIP> <SNIP> <SNIP> <SNIP> transfer_1 | Waiting for TCP connection to postgres:5432...OK transfer_1 | Received notification for accountupdate for dcf286bf-7011-40f5-abb0-153d94acde transfer_1 | Performing update of dcf286bf-7011-40f5-abb0-153d94acde69 transfer_1 | Indexing row dcf286bf-7011-40f5-abb0-153d94acde69 Mr. dcf286bf dcf286bf Esq. elasticsearch_1 | creating index, cause [auto(index api)], shards [5]/[1], mappings [] elasticsearch_1 | update_mapping [account] (dynamic) transfer_1 | Dispatch complete devweek15code_transfer_1 exited with code 0 Gracefully stopping... (press Ctrl+C again to force) Stopping devweek15code_elasticsearch_1... Stopping devweek15code_postgres_1...
  • 43. Compose Cleanup [ssmith] docker-compose ps Name Command State Ports -------------------------------------------------------------------------------- devweek15code_elasticsearch_1 /bin/sh -c /opt/elasticsea ... Exit -1 devweek15code_postgres_1 /docker-entrypoint.sh postgres Exit 0 devweek15code_transfer_1 /bin/sh -c waitport elasti ... Exit 0 [ssmith] docker-compose rm —force Going to remove devweek15code_transfer_1, devweek15code_elasticsearch_1, devweek15code_postgres_1 Removing devweek15code_postgres_1... Removing devweek15code_elasticsearch_1... Removing devweek15code_transfer_1… [ssmith] docker-compose ps Name Command State Ports -------------------------------------------------------------------------------- [ssmith]
  • 47. All New! Bamboo Docker Task!
  • 48. AWS cloud agents with Docker With Docker Or create your own
  • 49. Require Docker support Bamboo will start on-demand
  • 53. Compose with BambooSouth Florida Classical Review
  • 54. No Compose? No problem…
  • 58. Fetching container files [ssmith] docker-compose ps Name Command State Ports -------------------------------------------------------------------------------- devweek15code_elasticsearch_1 /bin/sh -c /opt/elasticsea ... Exit -1 devweek15code_postgres_1 /docker-entrypoint.sh postgres Exit 0 devweek15code_transfer_1 /bin/sh -c waitport elasti ... Exit 0 [ssmith] docker-compose ps -q transfer fd7e728e3e9a361d96c253f5aeadab1a3506538d1b0e19d27c82848d9bf48bf8 [ssmith] ID=`docker-compose ps -q transfer` [ssmith] docker cp $ID:/code/testreports.xml . [ssmith] file testreports.xml testreports.xml: XML document text
  • 69. 2 3 Useful Links https://www.docker.com/subscribe_newsletter/ 1 https://www.docker.com/ 4 http://www.nkode.io/2014/08/24/valuable-docker-links.html http://boot2docker.io/
  • 70. Thank you! STEVE SMITH • DEVOPS ADVOCATE • ATLASSIAN • @TARKASTEVE