Skip to content

Instantly share code, notes, and snippets.

View MichaelSimons's full-sized avatar

Michael Simons MichaelSimons

View GitHub Profile
@MichaelSimons
MichaelSimons / Current.README.md
Last active June 26, 2017 15:23
multi-arch docker readme possibilities

Supported tags and respective Dockerfile links

@MichaelSimons
MichaelSimons / manifest
Created August 31, 2017 03:27
Docker Manifest Sample
Name: microsoft/dotnet:2.0-runtime (Type: application/vnd.docker.distribution.manifest.list.v2+jso
Digest: sha256:9155380f6a89736a5e83ff692c47bf73ceddfc4f13387221d609d95ef38971a5
* Contains 3 manifest references:
1 Mfst Type: application/vnd.docker.distribution.manifest.v2+json
1 Digest: sha256:48fc531df679dff731402f499cc9e7fa87bfb0df504c8b0d042aecdd83d69615
1 Mfst Length: 1163
1 Platform:
1 - OS: linux
1 - OS Vers:
1 - OS Feat: []
@MichaelSimons
MichaelSimons / history.md
Created August 31, 2017 03:45
docker history sample

IMAGE CREATED CREATED BY SIZE COMMENT sha256:48e3f964cc7a7ba4df402c4c16d65bcf2192936a27f19414e5c93377cdd041f6 6 days ago /bin/sh -c #(nop) ENTRYPOINT ["dotnet" "dotnetapp.dll"] 0B
sha256:7e208544fd80118aede89faac3d6a71e7a213c44136b5644c7ae70cc5cbba43e 6 days ago /

@MichaelSimons
MichaelSimons / Keeping_runtime-deps_up-to-date.MD
Last active January 17, 2018 19:51
How to ensure the runtime-deps Docker images stay in-sync with the product

Problem Statement

The runtime-deps dockerfile currently has a static list of what the runtime dependencies are. There is no link (e.g. tooling that automatically updates the dependencies) to the actual dependencies the runtime has. Because of this, there is a potential for the Docker image to get out of sync with the runtime. The Docker repo CI includes tests which build a basic self-contained hello world application and runs it in the runtime-deps image but this is not extensive enough to fully validate the right set of dependencies are included in the image.

FROM debian:stretch

RUN apt-get update \
    && apt-get install -y --no-install-recommends \
        ca-certificates \
        \

SDK Docker Images Contain PowerShell Core

Per requests from the community, PowerShell Core has been added to the .NET Core Docker SDK images. PowerShell Core is a cross-platform (Windows, Linux, and macOS) automation and configuration tool/framework that works well with your existing tools and is optimized for dealing with structured data (e.g. JSON, CSV, XML, etc.), REST APIs, and object models. It includes a command-line shell, an associated scripting language and a framework for processing cmdlets.

If you are new to PowerShell and would like to learn more, we recommend reviewing the getting started documentation.

You can try out PowerShell Core by running the following Docker command:

docker run --rm mcr.microsoft.com/dotnet/core/sdk:3.0 pwsh -c Write-Host "Hello Powershell"

Image Tagging

The .NET Core image tags strive to align with the tagging practices utilized by the Official Images on Docker Hub.

Simple Tags

  1. <Major.Minor.Patch Version>-<OS>-<Architecture> - e.g. 2.2.5-alpine3.9, 2.1.11-stretch-slim-arm32v7, 3.0.0-nanoserver-1809, 5.0.0-preview1-disco-arm64
  2. <Major.Minor Version>-<OS>-<Architecture> - e.g. 2.2-alpine3.9, 2.1-stretch-slim-arm32v7, 3.0-nanoserver-1809

Shared Tags

@MichaelSimons
MichaelSimons / README.md
Created October 9, 2019 15:59
.NET Core Packaging to Support Docker Image Production

TODO

@MichaelSimons
MichaelSimons / RetrievingDockerImageSizes.md
Last active May 10, 2024 07:19
Retrieving Docker Image Sizes

Retrieving Docker Image Sizes

There are two metrics that are important to consider when discussing the size of Docker images.

  1. Compressed size - This is often referred to as the wire size. This affects how fast/slow images can be pulled from a registry. This impacts the first run experience on machines where images are not cached.
  2. Uncompressed size - This is often referred to as the size on disk. This affects how much local storage is required to support your Docker workloads.

The example commands shown below will work on Windows, MacOS, and Linux.

How to Measure the Compressed Size

@MichaelSimons
MichaelSimons / dotnet-core-release-test-plan.md
Last active January 23, 2020 18:54
.NET Core Release Test Plan

.NET Core Release Test Plan

Releasing .NET Core is a complex process involving many components, dependencies on external systems and different teams. With the growing usage and success of .NET Core, it is critical that we are able to release with confidence. This requires us to take necessary steps to validate each release was completed as expected. Ideally we would always release the product without issues but that has not been the case so far. We need tests in place to identify issues so that they can be addressed as part of the release tic-toc before customers are impacted.

This document describes how to validate .NET Core releases. This document describes at a broad level what should be validated. It is not intended to describe the minute details.

The document breaks down the items to validate into the following broad groups.

  • Acquisition Artifacts - The primary ways customers acquire the product. e.g. Native Installers
  • Auxiliary Artifacts - Auxiliary artifacts used with product. e.g. NuGet Pac
@MichaelSimons
MichaelSimons / dotnet-framework.csv
Last active March 11, 2020 19:56
dotnet-layer-info
We can make this file beautiful and searchable if this error is corrected: It looks like row 6 should actually have 8 columns, instead of 6. in line 5.
sha256:ca895ab76f1d3ab95f022cbca076e06b62daebafe61af34212bb3ed1fe982d78,amd64,windows,Windows Server 2016,4.8,4.8/runtime/windowsservercore-ltsc2016/Dockerfile,dotnet/framework/runtime,2020-03-11 13:52:00
4.8-20200211-windowsservercore-ltsc2016,amd64,windows,Windows Server 2016,4.8,4.8/runtime/windowsservercore-ltsc2016/Dockerfile,dotnet/framework/runtime,2020-03-11 13:52:00
4.8-windowsservercore-ltsc2016,amd64,windows,Windows Server 2016,4.8,4.8/runtime/windowsservercore-ltsc2016/Dockerfile,dotnet/framework/runtime,2020-03-11 13:52:00
sha256:4308c89ceac1a04af04590ecc56f2f3784ab1fdd21811a6426766cc817bcf9e5,amd64,windows,"Windows Server, version 1903",3.5,3.5/runtime/windowsservercore-1903/Dockerfile,dotnet/framework/runtime,2020-03-11 13:52:00
3.5-20200211-windowsservercore-1903,amd64,windows,"Windows Server, version 1903",3.5,3.5/runtime/windowsservercore-1903/Dockerfile,dotnet/framework/runtime,2020-03-11 13:52:00
3.5-windowsservercore-1903,amd64,windows,"Windows Server, version 1903",3.5,3.5/runtime/window