Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How can I stay on the latest SDK patch version? #465

Closed
Nefcanto opened this issue Mar 2, 2023 · 5 comments
Closed

How can I stay on the latest SDK patch version? #465

Nefcanto opened this issue Mar 2, 2023 · 5 comments

Comments

@Nefcanto
Copy link

Nefcanto commented Mar 2, 2023

Hello

I'm using your images for my development Docker image. This is my Dockerfile:

# https://mcr.microsoft.com/v2/vscode/devcontainers/dotnet/tags/list
ARG VARIANT="7.0-bullseye-slim"
FROM mcr.microsoft.com/vscode/devcontainers/dotnet:${VARIANT}

ENV PATH="${PATH}:/Company/Commands/ApiContainer"

ENV Nuget=/root/.local/share/NuGet/http-cache/

COPY . /Company/Infra

RUN mkdir /Temp \
    && cd /Temp \
    && dotnet new console \
    && echo '<Project Sdk="Microsoft.NET.Sdk.Web"><Import Project="/Company/Infra/DotNet.targets" /></Project>' > /Temp/Temp.csproj \
    && echo 'System.Console.WriteLine("hello");' > /Temp/Program.cs \
    && dotnet restore \
    && dotnet build \
    && cd / \
    && rm -rf /Temp

RUN apt update \
    && apt install bc -y \
    && apt install -y procps \
    && apt install gettext-base \
    && apt install apt-utils -y \
    && apt install libgdiplus -y \
    && apt install libc6-dev -y \
    && apt install webp -y \
    && apt install imagemagick -y \
    && cd /usr/local/bin \
    && curl https://getmic.ro | bash

However, when I build it, run a container from it, and enter into the container using docker exec -it container_name bash, and run the dotnet --info I see this message:

root ➜ / $ dotnet --info
.NET SDK:
 Version:   7.0.103
 Commit:    276c71d299

Runtime Environment:
 OS Name:     debian
 OS Version:  11
 OS Platform: Linux
 RID:         debian.11-x64
 Base Path:   /usr/share/dotnet/sdk/7.0.103/

Host:
  Version:      7.0.3
  Architecture: x64
  Commit:       0a2bda10e8

.NET SDKs installed:
  7.0.103 [/usr/share/dotnet/sdk]

.NET runtimes installed:
  Microsoft.AspNetCore.App 7.0.3 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
  Microsoft.NETCore.App 7.0.3 [/usr/share/dotnet/shared/Microsoft.NETCore.App]

Other architectures found:
  None

Environment variables:
  Not set

global.json file:
  Not found

Learn more:
  https://aka.ms/dotnet/info

Download .NET:
  https://aka.ms/dotnet/download

As you can see the .NET SDK version is 7.0.103.

However, at the same time, the .NET SDK version in its download page is 7.0.201.

I need to stay on the latest patch update. How can I do that?

@samruddhikhandale
Copy link
Member

Hi 👋

The .NET images are dependent on the upstream mcr.microsoft.com/dotnet/sdk images. That said, our dev tags have been updated with latest .NET version v7.0.201 - reference.

In the meanwhile, feel free to use mcr.microsoft.com/devcontainers/dotnet:dev-7.0 in your Dockerfile. I can help release the images today/tomorrow which will update the prod images.

@Nefcanto
Copy link
Author

Nefcanto commented Mar 3, 2023

@samruddhikhandale thank you for answering.

The problem with the upstream image is that it does not work for debugging in a container.

We tried that several times and we could not make it work. Maybe you have added extra stuff that makes it possible.

We need to be able to debug inside containers using the Dev Containers extension.

And I'm grateful that you are doing this update. However, I'm not asking about this one instance. I'm asking in general to see what options do we have, to always stay on the latest SDK release.

@samruddhikhandale
Copy link
Member

We do have a monthly release cadence for all the images, which happens in the first week. Besides that, we have in between releases depending upon patches and bug fixes. However, if we have an issue asking us to release an image to update it, then we are happy to take such requests as well.

For major version releases, let's say .NET 8 is released, then we support it immediately. Look at the tracking issue #90 for more details.

@Nefcanto
Copy link
Author

Nefcanto commented Mar 4, 2023

@samruddhikhandale thank you for the detailed answer. So we can stay sure that we won't stay behind Microsoft for more than a month. That's very good. Thank you.

@samruddhikhandale
Copy link
Member

As you can see the .NET SDK version is 7.0.103.

However, at the same time, the .NET SDK version in its download page is 7.0.201.

Closing as .Net images are updated 🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants
@Nefcanto @samruddhikhandale and others