Search icon CANCEL
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Docker on Windows
Docker on Windows

Docker on Windows: From 101 to production with Docker on Windows , Second Edition

eBook
€22.99 €32.99
Paperback
€41.99
Subscription
Free Trial
Renews at €18.99p/m

What do you get with Print?

Product feature icon Instant access to your digital eBook copy whilst your Print order is Shipped
Product feature icon Paperback book shipped to your preferred address
Product feature icon Download this book in EPUB and PDF formats
Product feature icon Access this title in our online reader with advanced features
Product feature icon DRM FREE - Read whenever, wherever and however you want
Product feature icon AI Assistant (beta) to help accelerate your learning
Table of content icon View table of contents Preview book icon Preview Book

Docker on Windows

Getting Started with Docker on Windows

Docker is an application platform. It's a new way of running applications in isolated, lightweight units called containers. Containers are a very efficient way of running apps – much more efficient than virtual machines (VMs) or bare-metal servers. Containers start in seconds, and they don't add any overhead to the memory and compute requirements of an app. Docker is completely agnostic to the type of apps it can run. You can run a brand new .NET Core app in one container and a 10-year old ASP.NET 2.0 WebForms app in another container on the same server.

Containers are isolated units, but they can integrate with other components. Your WebForms container can access a REST API hosted in your .NET Core container. Your .NET Core container can access a SQL Server database running in a container, or a SQL Server instance running...

Technical requirements

Docker and Windows containers

Docker was originally developed on Linux, taking advantage of core Linux features, but making it simple and efficient to use containers for application workloads. Microsoft saw the potential and worked closely with the Docker engineering team to bring the same functionality to Windows.

Windows Server 2016 was the first version of Windows built to run Docker containers; Windows Server 2019 continues the innovation with significantly improved features and performance for Windows containers. You can run the same Docker containers on Windows 10 for development and testing that you run on Windows Server in production. Right now, you can only run Windows applications in containers on Windows, but Microsoft is adding support for Linux application containers to run on Windows too.

The first thing you need to know is that there is no integration between containers...

Understanding the key Docker concepts

Docker is a very powerful but very simple application platform. You can get started with running your existing apps in Docker in just a few days, and be ready to move to production in another few days. This book will take you through lots of examples of .NET Framework and .NET Core applications running in Docker. You'll learn how to build, ship, and run applications in Docker and move on to advanced topics such as solution design, security, administration, instrumentation, and continuous integration and continuous delivery (CI/CD).

To start with, you need to understand the core Docker concepts: images, registries, containers, and orchestrators – and understand how Docker actually runs.

The Docker Engine and Docker command-line

...

Running Docker on Windows

It's easy to install Docker on Windows 10, using Docker Desktop – a Windows package that sets up all the prerequisites, deploys the latest version of the Docker Community Engine, and gives you a UI with some useful options to manage image repositories and remote clusters.

In production, you should ideally use Windows Server 2019 Core, the installation with no UI. This reduces the attack surface and the amount of Windows updates your server will need. If you move all your apps to Docker, you won't need any other Windows features installed; you'll just have Docker Engine running as a Windows service.

I'll walk through both of these installation options and show you a third option using a VM in Azure, which is useful if you want to try Docker but don't have access to Windows 10 or Windows Server 2019.

There is a fantastic...

Learning about Docker with this book

Every code listing in this book is accompanied by a full code sample on my GitHub repository at https://github.com/sixeyed/docker-on-windows. There's a branch for this edition of the book, called second-edition. The source tree is organized into a folder for each chapter, and for each chapter there's a folder for each code sample. In this chapter, I've used three samples to create Docker images, which you'll find in ch01\ch01-whale, ch01\ch01-az, and ch01\ch01-dockertls.

The code listings in this book may be condensed, but the full code can always be found in the GitHub repository.

I prefer to follow along with code samples when I'm learning a new technology, but if you want to use working versions of the demo applications, every sample is also available as a public Docker image on Docker Hub. Wherever you see a docker...

Summary

In this chapter I introduced Docker, an application platform which can run new and old apps in lightweight units of compute called containers. Companies are moving to Docker for efficiency, security, and portability. I covered the following topics:

  • How Docker works on Windows and how containers are licensed.
  • The key Docker concepts: images, registries, containers, and orchestrators.
  • The options to run Docker on Windows 10, Windows Server 2019, or Azure.

If you're planning to work along with the code samples in the rest of the book, you should have a working Docker environment by now. In Chapter 2, Packaging and Running Applications as Docker Containers, I'll move onto packaging more complex apps as Docker images and show how to manage states in containers with Docker volumes.

Left arrow icon Right arrow icon
Download code icon Download Code

Key benefits

  • Run .NET Framework and .NET Core apps in Docker containers for efficiency, security and portability
  • Design distributed containerized apps, using enterprise-grade open source software from Docker Hub
  • Build a CI/CD pipeline with Docker, going from source to a production Docker Swarm in the cloud

Description

Docker on Windows, Second Edition teaches you all you need to know about Docker on Windows, from the 101 to running highly-available workloads in production. You’ll be guided through a Docker journey, starting with the key concepts and simple examples of .NET Framework and .NET Core apps in Docker containers on Windows. Then you’ll learn how to use Docker to modernize the architecture and development of traditional ASP.NET and SQL Server apps. The examples show you how to break up legacy monolithic applications into distributed apps and deploy them to a clustered environment in the cloud, using the exact same artifacts you use to run them locally. You’ll see how to build a CI/CD pipeline which uses Docker to compile, package, test and deploy your applications. To help you move confidently to production, you’ll learn about Docker security, and the management and support options. The book finishes with guidance on getting started with Docker in your own projects. You’ll walk through some real-world case studies for Docker implementations, from small-scale on-premises apps to very large-scale apps running on Azure.

Who is this book for?

If you want to modernize an old monolithic application without rewriting it, smooth the deployment to production, or move to DevOps or the cloud, then Docker is the enabler for you. This book gives you a solid grounding in Docker so you can confidently approach all of these scenarios.

What you will learn

  • Understand key Docker concepts: images, containers, registries and swarms
  • Run Docker on Windows 10, Windows Server 2019, and in the cloud
  • Deploy and monitor distributed solutions across multiple Docker containers
  • Run containers with high availability and failover with Docker Swarm
  • Master security in-depth with the Docker platform, making your apps more secure
  • Build a Continuous Deployment pipeline, running Jenkins and Git in Docker
  • Debug applications running in Docker containers using Visual Studio
  • Plan the adoption of Docker in your organization
Estimated delivery fee Deliver to Romania

Premium delivery 7 - 10 business days

€25.95
(Includes tracking information)

Product Details

Country selected
Publication date, Length, Edition, Language, ISBN-13
Publication date : Feb 28, 2019
Length: 428 pages
Edition : 2nd
Language : English
ISBN-13 : 9781789617375
Vendor :
Docker
Tools :

What do you get with Print?

Product feature icon Instant access to your digital eBook copy whilst your Print order is Shipped
Product feature icon Paperback book shipped to your preferred address
Product feature icon Download this book in EPUB and PDF formats
Product feature icon Access this title in our online reader with advanced features
Product feature icon DRM FREE - Read whenever, wherever and however you want
Product feature icon AI Assistant (beta) to help accelerate your learning
Estimated delivery fee Deliver to Romania

Premium delivery 7 - 10 business days

€25.95
(Includes tracking information)

Product Details

Publication date : Feb 28, 2019
Length: 428 pages
Edition : 2nd
Language : English
ISBN-13 : 9781789617375
Vendor :
Docker
Tools :

Packt Subscriptions

See our plans and pricing
Modal Close icon
€18.99 billed monthly
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Simple pricing, no contract
€189.99 billed annually
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Choose a DRM-free eBook or Video every month to keep
Feature tick icon PLUS own as many other DRM-free eBooks or Videos as you like for just €5 each
Feature tick icon Exclusive print discounts
€264.99 billed in 18 months
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Choose a DRM-free eBook or Video every month to keep
Feature tick icon PLUS own as many other DRM-free eBooks or Videos as you like for just €5 each
Feature tick icon Exclusive print discounts

Frequently bought together


Stars icon
Total 104.97
Docker High Performance
€20.99
Docker on Windows
€41.99
Mastering Docker
€41.99
Total 104.97 Stars icon

Table of Contents

17 Chapters
Section 1: Understanding Docker and Windows Containers Chevron down icon Chevron up icon
Getting Started with Docker on Windows Chevron down icon Chevron up icon
Packaging and Running Applications as Docker Containers Chevron down icon Chevron up icon
Developing Dockerized .NET Framework and .NET Core Applications Chevron down icon Chevron up icon
Sharing Images with Docker Registries Chevron down icon Chevron up icon
Section 2: Designing and Building Containerized Solutions Chevron down icon Chevron up icon
Adopting Container-First Solution Design Chevron down icon Chevron up icon
Organizing Distributed Solutions with Docker Compose Chevron down icon Chevron up icon
Orchestrating Distributed Solutions with Docker Swarm Chevron down icon Chevron up icon
Section 3: Preparing for Docker in Production Chevron down icon Chevron up icon
Administering and Monitoring Dockerized Solutions Chevron down icon Chevron up icon
Understanding the Security Risks and Benefits of Docker Chevron down icon Chevron up icon
Powering a Continuous Deployment Pipeline with Docker Chevron down icon Chevron up icon
Section 4: Getting Started on Your Container Journey Chevron down icon Chevron up icon
Debugging and Instrumenting Application Containers Chevron down icon Chevron up icon
Containerize What You Know - Guidance for Implementing Docker Chevron down icon Chevron up icon
Other Books You May Enjoy Chevron down icon Chevron up icon

Customer reviews

Rating distribution
Full star icon Full star icon Full star icon Full star icon Full star icon 5
(5 Ratings)
5 star 100%
4 star 0%
3 star 0%
2 star 0%
1 star 0%
treesa Dec 16, 2020
Full star icon Full star icon Full star icon Full star icon Full star icon 5
This is interdisciplinary. The concepts are amazing but the devil’s in the details. Not possible to work with the book alone. You need the associated code and then a lot of internet research on top of that. It’s been a few months and only just finished Chapter 6. Learning tons, though.
Amazon Verified review Amazon
Ferran May 07, 2019
Full star icon Full star icon Full star icon Full star icon Full star icon 5
If you are planning to move your existing Windows application into Docker containers, this book will help you gain knowledge to support it. In the book the author takes a monolithic .NET based application, containerizes it and subsequently breaks it down into micro-services. He then provides guidance as to how to share it, and setup a secure and continuous delivery pipeline.The book is very hands-on and meant to be used in conjunction with the source code (provided for free on Github), so get ready to get your coding going on!
Amazon Verified review Amazon
Lilian Sep 02, 2019
Full star icon Full star icon Full star icon Full star icon Full star icon 5
I had the privilege of attending a couple of Elton's presentations @Live conference. This book is a must have for anyone going through the journey of breaking up the monolith, learning how to solve typical problems using Docker. Elton's expertize in the subject matter is expressed throughout the book with clear hands on examples. His advice is invaluable.
Amazon Verified review Amazon
Steven Follis May 15, 2019
Full star icon Full star icon Full star icon Full star icon Full star icon 5
This book is a perfect introduction to running Docker Containers within the Microsoft Windows ecosystem. From applications themselves to integrations such as persistent storage, I felt confident in being able to work with containers. Having read the first edition, this 2nd edition expands and provides more detail around the recently released Windows Server 2019 operating system. Recommended for anyone interacting with Windows Containers on a regular basis.
Amazon Verified review Amazon
Pav May 20, 2019
Full star icon Full star icon Full star icon Full star icon Full star icon 5
I am a Docker Captain and have been working with Docker on Linux for years. I am new however to Docker on Windows ecosystem. This book is a great way to get started running containers on windows. Whether you are running a single container in dev or supporting production environment -- you will find relevant information in this book. Not at all intimidating to a beginner and still full of useful info for a more experienced user. Tips and tricks and windows idiosyncrasies are well covered throughout the book. Highly recommend as the reference guide for anyone running Docker on Windows.
Amazon Verified review Amazon
Get free access to Packt library with over 7500+ books and video courses for 7 days!
Start Free Trial

FAQs

What is the delivery time and cost of print book? Chevron down icon Chevron up icon

Shipping Details

USA:

'

Economy: Delivery to most addresses in the US within 10-15 business days

Premium: Trackable Delivery to most addresses in the US within 3-8 business days

UK:

Economy: Delivery to most addresses in the U.K. within 7-9 business days.
Shipments are not trackable

Premium: Trackable delivery to most addresses in the U.K. within 3-4 business days!
Add one extra business day for deliveries to Northern Ireland and Scottish Highlands and islands

EU:

Premium: Trackable delivery to most EU destinations within 4-9 business days.

Australia:

Economy: Can deliver to P. O. Boxes and private residences.
Trackable service with delivery to addresses in Australia only.
Delivery time ranges from 7-9 business days for VIC and 8-10 business days for Interstate metro
Delivery time is up to 15 business days for remote areas of WA, NT & QLD.

Premium: Delivery to addresses in Australia only
Trackable delivery to most P. O. Boxes and private residences in Australia within 4-5 days based on the distance to a destination following dispatch.

India:

Premium: Delivery to most Indian addresses within 5-6 business days

Rest of the World:

Premium: Countries in the American continent: Trackable delivery to most countries within 4-7 business days

Asia:

Premium: Delivery to most Asian addresses within 5-9 business days

Disclaimer:
All orders received before 5 PM U.K time would start printing from the next business day. So the estimated delivery times start from the next day as well. Orders received after 5 PM U.K time (in our internal systems) on a business day or anytime on the weekend will begin printing the second to next business day. For example, an order placed at 11 AM today will begin printing tomorrow, whereas an order placed at 9 PM tonight will begin printing the day after tomorrow.


Unfortunately, due to several restrictions, we are unable to ship to the following countries:

  1. Afghanistan
  2. American Samoa
  3. Belarus
  4. Brunei Darussalam
  5. Central African Republic
  6. The Democratic Republic of Congo
  7. Eritrea
  8. Guinea-bissau
  9. Iran
  10. Lebanon
  11. Libiya Arab Jamahriya
  12. Somalia
  13. Sudan
  14. Russian Federation
  15. Syrian Arab Republic
  16. Ukraine
  17. Venezuela
What is custom duty/charge? Chevron down icon Chevron up icon

Customs duty are charges levied on goods when they cross international borders. It is a tax that is imposed on imported goods. These duties are charged by special authorities and bodies created by local governments and are meant to protect local industries, economies, and businesses.

Do I have to pay customs charges for the print book order? Chevron down icon Chevron up icon

The orders shipped to the countries that are listed under EU27 will not bear custom charges. They are paid by Packt as part of the order.

List of EU27 countries: www.gov.uk/eu-eea:

A custom duty or localized taxes may be applicable on the shipment and would be charged by the recipient country outside of the EU27 which should be paid by the customer and these duties are not included in the shipping charges been charged on the order.

How do I know my custom duty charges? Chevron down icon Chevron up icon

The amount of duty payable varies greatly depending on the imported goods, the country of origin and several other factors like the total invoice amount or dimensions like weight, and other such criteria applicable in your country.

For example:

  • If you live in Mexico, and the declared value of your ordered items is over $ 50, for you to receive a package, you will have to pay additional import tax of 19% which will be $ 9.50 to the courier service.
  • Whereas if you live in Turkey, and the declared value of your ordered items is over € 22, for you to receive a package, you will have to pay additional import tax of 18% which will be € 3.96 to the courier service.
How can I cancel my order? Chevron down icon Chevron up icon

Cancellation Policy for Published Printed Books:

You can cancel any order within 1 hour of placing the order. Simply contact customercare@packt.com with your order details or payment transaction id. If your order has already started the shipment process, we will do our best to stop it. However, if it is already on the way to you then when you receive it, you can contact us at customercare@packt.com using the returns and refund process.

Please understand that Packt Publishing cannot provide refunds or cancel any order except for the cases described in our Return Policy (i.e. Packt Publishing agrees to replace your printed book because it arrives damaged or material defect in book), Packt Publishing will not accept returns.

What is your returns and refunds policy? Chevron down icon Chevron up icon

Return Policy:

We want you to be happy with your purchase from Packtpub.com. We will not hassle you with returning print books to us. If the print book you receive from us is incorrect, damaged, doesn't work or is unacceptably late, please contact Customer Relations Team on customercare@packt.com with the order number and issue details as explained below:

  1. If you ordered (eBook, Video or Print Book) incorrectly or accidentally, please contact Customer Relations Team on customercare@packt.com within one hour of placing the order and we will replace/refund you the item cost.
  2. Sadly, if your eBook or Video file is faulty or a fault occurs during the eBook or Video being made available to you, i.e. during download then you should contact Customer Relations Team within 14 days of purchase on customercare@packt.com who will be able to resolve this issue for you.
  3. You will have a choice of replacement or refund of the problem items.(damaged, defective or incorrect)
  4. Once Customer Care Team confirms that you will be refunded, you should receive the refund within 10 to 12 working days.
  5. If you are only requesting a refund of one book from a multiple order, then we will refund you the appropriate single item.
  6. Where the items were shipped under a free shipping offer, there will be no shipping costs to refund.

On the off chance your printed book arrives damaged, with book material defect, contact our Customer Relation Team on customercare@packt.com within 14 days of receipt of the book with appropriate evidence of damage and we will work with you to secure a replacement copy, if necessary. Please note that each printed book you order from us is individually made by Packt's professional book-printing partner which is on a print-on-demand basis.

What tax is charged? Chevron down icon Chevron up icon

Currently, no tax is charged on the purchase of any print book (subject to change based on the laws and regulations). A localized VAT fee is charged only to our European and UK customers on eBooks, Video and subscriptions that they buy. GST is charged to Indian customers for eBooks and video purchases.

What payment methods can I use? Chevron down icon Chevron up icon

You can pay with the following card types:

  1. Visa Debit
  2. Visa Credit
  3. MasterCard
  4. PayPal
What is the delivery time and cost of print books? Chevron down icon Chevron up icon

Shipping Details

USA:

'

Economy: Delivery to most addresses in the US within 10-15 business days

Premium: Trackable Delivery to most addresses in the US within 3-8 business days

UK:

Economy: Delivery to most addresses in the U.K. within 7-9 business days.
Shipments are not trackable

Premium: Trackable delivery to most addresses in the U.K. within 3-4 business days!
Add one extra business day for deliveries to Northern Ireland and Scottish Highlands and islands

EU:

Premium: Trackable delivery to most EU destinations within 4-9 business days.

Australia:

Economy: Can deliver to P. O. Boxes and private residences.
Trackable service with delivery to addresses in Australia only.
Delivery time ranges from 7-9 business days for VIC and 8-10 business days for Interstate metro
Delivery time is up to 15 business days for remote areas of WA, NT & QLD.

Premium: Delivery to addresses in Australia only
Trackable delivery to most P. O. Boxes and private residences in Australia within 4-5 days based on the distance to a destination following dispatch.

India:

Premium: Delivery to most Indian addresses within 5-6 business days

Rest of the World:

Premium: Countries in the American continent: Trackable delivery to most countries within 4-7 business days

Asia:

Premium: Delivery to most Asian addresses within 5-9 business days

Disclaimer:
All orders received before 5 PM U.K time would start printing from the next business day. So the estimated delivery times start from the next day as well. Orders received after 5 PM U.K time (in our internal systems) on a business day or anytime on the weekend will begin printing the second to next business day. For example, an order placed at 11 AM today will begin printing tomorrow, whereas an order placed at 9 PM tonight will begin printing the day after tomorrow.


Unfortunately, due to several restrictions, we are unable to ship to the following countries:

  1. Afghanistan
  2. American Samoa
  3. Belarus
  4. Brunei Darussalam
  5. Central African Republic
  6. The Democratic Republic of Congo
  7. Eritrea
  8. Guinea-bissau
  9. Iran
  10. Lebanon
  11. Libiya Arab Jamahriya
  12. Somalia
  13. Sudan
  14. Russian Federation
  15. Syrian Arab Republic
  16. Ukraine
  17. Venezuela