Im using an a dotnet image in jenkins in order to execute dotnet-outdated command
here is my image code
FROM /baseimages/microsoft/dotnet/core/sdk:6.0-alpine //this link is private i cannot share but he gives the dotnet image
RUN dotnet tool install --global dotnet-outdated-tool --version 4.1.0
ENV PATH="$PATH:/root/.dotnet/tools"
ENTRYPOINT ["sh"]
i get the image from harbor, when i tried the image on docker, the command run without a problem, but when i try it on jenkins it doesnt work
here is the code in jenkins
stage('getFolder') {
container('dotnet-outdated') {
sh """
dotnet --version
dotnet-outdated --version
"""
}
}
the dotnet --version works fine
but the dotnet outdated doesnt work
this is the error

the environment is already set
envVars: [
envVar(key: 'DOTNET_CLI_HOME', value: '/tmp/dotnet_cli'),
],