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

Offline support? #287

Open
coryisakson opened this issue Mar 1, 2021 · 6 comments
Open

Offline support? #287

coryisakson opened this issue Mar 1, 2021 · 6 comments
Labels
community reported enhancement New feature or request Triaged Label to show that UA team has triaged this issue. User Story

Comments

@coryisakson
Copy link

I would like to use the upgrade assistant with a customer that has their source code in a disconnected (no Internet) environment. Is it possible to install and run the assistant offline?

@mjrousos mjrousos added community reported enhancement New feature or request labels Mar 1, 2021
@mjrousos
Copy link
Member

mjrousos commented Mar 1, 2021

@coryisakson, running offline isn't currently supported, unfortunately. The main issue is that some of the steps (upgrading the project file format and upgrading NuGet package dependencies) require internet access to determine which versions of a NuGet package will work on .NET 5.

I'll leave this issue open to track the request for an offline mode, as I agree that it would be useful to have the option to run offline (though some functionality may not work in that mode).

@sunandabalu sunandabalu added the Triaged Label to show that UA team has triaged this issue. label Apr 20, 2021
@sunandabalu
Copy link
Member

/cc @twsouthwick

@twsouthwick
Copy link
Member

@coryisakson We'd like to understand your scenario a bit more here. Is this a fully air gapped solution? Or is there a way to get some access to the internet? Are they currently using package management?

The only part of the tool that requires the internet at this time is NuGet related. A quick idea would be the following:

  • Run the tool to identify a list of external data that is needed
  • Take that list and run a separate command on a networked machine to get a list of updated data.
  • Take the list of updated data back to the tool and run the tool with that as an input

This would allow the tool to work without needing internet on the machine with the source code, but an internet connected machine would still be needed.

@paulomorgado
Copy link

On the general case, regarding NuGet, you can use the NuGet CLI init command to create a source on a local folder and just add the .nupkg files to that source.

@superstrom
Copy link

not OP, but I have a similar situation. I am trying to run on an airgapped system, however I have a NuGet repository (via a self-hosted SonaType Nexus instance), which is fully configured and working as a package source in dotnet and nuget.exe.

It appears that setting NuGetDownloaderOptions.PackageSourcePath to anything other than null should allow GetPackageSources to use the NuGet.config configured sources, however PackageSourcePath seems to always be null despite attemts to inject a value via appSettings.json, etc.

services.AddSingleton(ctx => ctx.GetRequiredService<INuGetPackageSourceFactory>().GetPackageSources(ctx.GetRequiredService<IOptions<NuGetDownloaderOptions>>().Value.PackageSourcePath));

@superstrom
Copy link

why can't it by default just use all the configured sources?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
community reported enhancement New feature or request Triaged Label to show that UA team has triaged this issue. User Story
Projects
None yet
Development

No branches or pull requests

7 participants