Azure-Samples / dotnet-core-api

A simple ASP.NET Core API application that demonstrates how to run API apps in Azure App Service.
MIT License
123 stars 694 forks source link

NuGet.targets error: Access to path '/var/nuget/system.net.nameresolutionh.4.3.0' is denied #2

Closed abitofhelp closed 4 years ago

abitofhelp commented 5 years ago

This issue is for a: (mark with an x)

- [X ] bug report -> please search issues before submitting
- [ ] feature request
- [ ] documentation issue or request
- [ ] regression (a behavior that used to work and stopped in a new release)

Minimal steps to reproduce

On an Ubuntu 18.10 system on which mono, dotnetcore sdk, have been installed, follow the procedure in your document:

https://docs.microsoft.com/en-us/azure/app-service/containers/tutorial-auth-aad

The errors happen after entering: git push backend master

root@ububox:~/git/learning/dotnet-core-api/mike2/dotnet-core-api# git remote add backend "https://ingiosdashboardftp@adotnetcore-api.scm.azurewebsites.net/adotnetcore-api.git" root@ububox:~/git/learning/dotnet-core-api/mike2/dotnet-core-api# git push backend master Enumerating objects: 65, done. Counting objects: 100% (65/65), done. Delta compression using up to 8 threads Compressing objects: 100% (62/62), done. Writing objects: 100% (65/65), 17.79 KiB | 4.45 MiB/s, done. Total 65 (delta 19), reused 0 (delta 0) remote: Deploy Async remote: Updating branch 'master'. remote: Updating submodules. remote: Preparing deployment for commit id '80172f47da'. remote: Generating deployment script. remote: Project file path: ./TodoApi.csproj remote: Generated deployment script files remote: Running deployment command... remote: Handling ASP.NET Core Web Application deployment. remote: ... remote: Restoring packages for /home/site/repository/TodoApi.csproj... remote: ......... remote: Installing System.Collections.Immutable 1.3.0. . . . remote: Installing Microsoft.DotNet.InternalAbstractions 1.0.0. remote: /opt/dotnet/2.2.104/sdk/2.2.104/NuGet.targets(114,5): error : Access to the path '/var/nuget/system.net.nameresolution/4.3.0' is denied. [/home/site/repository/TodoApi.csproj] remote: /opt/dotnet/2.2.104/sdk/2.2.104/NuGet.targets(114,5): error : Permission denied [/home/site/repository/TodoApi.csproj] remote: An error has occurred during web site deployment. remote: dotnet restore failed remote: App container will begin restart within 10 seconds. remote: Deployment Logs : 'https://adotnetcore-api.scm.azurewebsites.net/newui/jsonviewer?view_url=/api/deployments/80172f47da2014d399da68a8bf5e3d4c8260b712/log' To https://adotnetcore-api.scm.azurewebsites.net/adotnetcore-api.git

I have tried to work-around this issue by manually creating the folders, running as root, but to no avail.

Any log messages given by the failure

remote: /opt/dotnet/2.2.104/sdk/2.2.104/NuGet.targets(114,5): error : Access to the path '/var/nuget/system.net.nameresolution/4.3.0' is denied. [/home/site/repository/TodoApi.csproj] remote: /opt/dotnet/2.2.104/sdk/2.2.104/NuGet.targets(114,5): error : Permission denied [/home/site/repository/TodoApi.csproj] remote: An error has occurred during web site deployment. remote: dotnet restore failed remote: App container will begin restart within 10 seconds.

Expected/desired behavior

Success

OS and Version?

Windows 7, 8 or 10. Linux (which distribution). macOS (Yosemite? El Capitan? Sierra?) Ubuntu 18.10

Versions

Mention any other details that might be useful


Thanks! We'll be in touch soon.

jevonsflash commented 2 years ago

Did you fix the problem? Why did you close the issue?