-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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
New image for ubuntu-latest docker issues #10646
Comments
We are seeing this problem as well, tested in ubuntu 24.04 as well and same problem there. |
We also have this problem. |
Hi @BBTristanBenschop , Thank you for bringing this issue to us. We are looking into this issue and will update you on this issue after investigating. |
Temporarily fix for us is switching to ubuntu-20.04 image where this issue doesn't exist. |
Hi @SpaceOgre @BBTristanBenschop ,
|
YAML file# ASP.NET Core
# Build and test ASP.NET Core projects targeting .NET Core.
# Add steps that run tests, create a NuGet package, deploy, and more:
# https://docs.microsoft.com/azure/devops/pipelines/languages/dotnet-core
trigger:
- main
pool:
vmImage: ubuntu-latest
variables:
buildConfiguration: "Release"
steps:
- task: UseDotNet@2
displayName: "Use .NET 8 sdk"
inputs:
packageType: "sdk"
version: "8.0.x"
# This is needed for the dotnet tool install commands to work, the dotnet restore command should work without it but I keep it at the top just in case.
- task: NuGetAuthenticate@1
displayName: "Authenticate with NuGet"
- task: DotNetCoreCLI@2
displayName: dotnet restore
inputs:
command: restore
projects: '**/*.csproj'
feedRestore: GR.Library
- task: DotNetCoreCLI@2
inputs:
command: custom
custom: format
arguments: "--verify-no-changes --verbosity diagnostic"
displayName: Check formatting
- task: DotNetCoreCLI@2
displayName: "dotnet build $(buildConfiguration)"
inputs:
command: build
projects: "**/*.csproj"
arguments: "--configuration $(buildConfiguration)"
- task: DotNetCoreCLI@2
displayName: Dotnet test
inputs:
command: "test"
projects: "tests/**/*.csproj"
publishTestResults: true
arguments: '--configuration $(buildConfiguration) --collect:"Code Coverage" --settings:devops/CodeCoverage.runsettings'
- task: DotNetCoreCLI@2
displayName: "Install dotnet-coverage"
inputs:
command: custom
custom: tool
arguments: "install --global dotnet-coverage"
- task: DotNetCoreCLI@2
displayName: "Install ReportGenerator"
inputs:
command: custom
custom: tool
arguments: "install --global dotnet-reportgenerator-globaltool"
# This step is needed for the reportgenerator to work, since we use the Code Coverage collect during tests and the reportgenerator does not support it.
# It is done like this so we can get code coverage results in Pull Request and get a full report to download and look at if needed.
- script: dotnet-coverage merge -r -f cobertura -o merged.cobertura.xml $(Agent.WorkFolder)/*.coverage
displayName: Merge code coverage files
- script: reportgenerator -reports:merged.cobertura.xml -targetdir:$(Build.SourcesDirectory)/CodeCoverage -reporttypes:'HtmlInline' -classfilters:+GR.PRIIS.*
displayName: Create Html Report for Code Coverage
- task: PublishBuildArtifacts@1
displayName: "Publish code coverage html report as artifact"
inputs:
PathtoPublish: "$(Build.SourcesDirectory)/CodeCoverage"
ArtifactName: "CodeCoverage"
publishLocation: "Container"
Docker partWe are starting docker in the |
Can confirm that we experience a similar issue on our side as well, related to our TestContainers usage. We reverted our workflows to use ubuntu-20.04 (which gave us the ubuntu-20.04.6 revision of the image) and that works for us for most of our workflows. Thanks for the tip @BBTristanBenschop. |
@kishorekumar-anchala we use a very similar setup as SpaceOgre including the use of TestContainers. It fails on running the tests which makes use of TestContainer library. |
@kishorekumar-anchala Adding some more context from stdout: Failing in 24.04
How it looks when it works in 20.04
|
Our mssql container failed in CI/CD with really odd messages like:
We noticed, the runner images have been update by Github. This was our Github Action Host machine image from a few days ago
This is the version we see today, that fail.
I believe the Linux kernel change from 6.5 to 6.8 is the reason this is failing. 🎉We fixed our issue by using the Ubuntu 20.04 runner image because both 22 and 24 have been affected as you can read in this issue on Github: #10646 to fix docker issues in your workflow.yml, make the following change:
|
Related issue: |
It looks like another workaround is bumping the image to:
|
If you don't want to upgrade to SQLServer 2022, I've confirmed the tag |
Hi @SpaceOgre @BBTristanBenschop , We request you to try below workaround. https://github.com/RaviAkshintala/testcontainers-dotnet/actions/runs/10993413941/workflow#L38 |
This works well for us and we will go with this solution, just a heads up to anyone else reading this: |
Is the workaround to start the docker image manually and not through TestContainers? Not sure I follow completely. But it would be good if it was possible to specify exactly wich runner version we are using and not just the OS-version, if something like this happens again since it was a bit of a problem this time. |
We have also opted to increase the image version of the sql server. We don't call docker directly, its hidden somewhere in TestContainers package. |
I'll add my two cents here saying that our workflows (that start up a dockerized SQL server 2019 ( The patch number (.4 and .5) can't be specified by the developer (source), which makes sense, as they contain security updates. This workaround by @BBTristanBenschop worked for me:
However I was left wondering that if the patch update from ubuntu-22.04.4 to 22.04.5 broke something, why hasn't the same (breaking) patch been applied to ubuntu-20.04, which still works? |
Hi @SpaceOgre @BBTristanBenschop , Could you try with the new image version (20241006.1) . it might fix your issue. |
Hi @SpaceOgre @BBTristanBenschop , Could you please share your confirmation on this issue ? |
HI @SpaceOgre @BBTristanBenschop , We hope that this has been fixed and we are closing this issue. Thank you ! |
Description
When starting a docker container in our devops pipeline since last night we receive the error:
Docker.DotNet.DockerApiException : Docker API responded with status code=Conflict, response={"message":"container f111f68d35dc63185d89a5d93600a4af7fdb01513d9e17f873aa400c3dc0c6da is not running"}
Platforms affected
Runner images affected
Image version and build link
We are using ubuntu-latest
Agent name: 'Hosted Agent'
Agent machine name: 'fv-az366-67'
Current agent version: '3.243.1'
Operating System
Runner Image
Runner Image Provisioner
Current image version: '20240915.1.0'
Agent running as: 'vsts'
the last working version is:
Agent name: 'Azure Pipelines 2'
Agent machine name: 'fv-az634-412'
Current agent version: '3.243.1'
Operating System
Runner Image
Runner Image Provisioner
Current image version: '20240908.1.0'
Agent running as: 'vsts'
Is it regression?
Current image version: '20240908.1.0'
Expected behavior
To properly startup the docker container so that our tests can be ran inside the container.
Actual behavior
Fails to start docker container
Repro steps
Start a docker container
The text was updated successfully, but these errors were encountered: