Skip to content

Instantly share code, notes, and snippets.

View MichaelSimons's full-sized avatar

Michael Simons MichaelSimons

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

TODO

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

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"
@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 \
        \
@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 / 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 / Current.README.md
Last active June 26, 2017 15:23
multi-arch docker readme possibilities

Supported tags and respective Dockerfile links