Welcome to the Inedo Forums! Check out the Forums Guide for help getting started.
If you are experiencing any issues with the forum software, please visit the Contact Form on our website and let us know!
PowerShell feed for modules & scripts
-
I've recently installed ProGet (using IIS) and am able to login, and create a PowerShell feed.
Looking at the docs, it says to register the repo using:
Register-PSRepository -Name MyProGetFeed -SourceLocation <ProGetUrl>/nuget/<FeedName>/api/v2 -PublishLocation <ProGetUrl>/nuget/<FeedName>/api/v2/packageHowever, this throws an error that "the specified URI for parameter SourceLocation is an invalid Web URI".
Changing the source location to the 'API Endpoint URL' displayed on the Feed page seems to work.
However, I'm not having any luck configuring the repo to support modules AND scripts as the SourceLocation and ScriptSourceLocation have to be different.
Anyone had any luck on this?
Product: ProGet
Version: 5.1.4
-
I'm afraid I'm not familiar enough with PowerShellGet to give advice on how to resolve this; it seems to be a client bug or configuration problem, and best place to seek help would be on their forums / issue tracker.
Please take a look at PowerShellGet Issue #76, which seems to discuss this and provide a workaround...
-
My workaround for supporting scripts and modules is to essentially trick it.
either specify the source and script source with the fqdn version of the url and then a shortversion of the url or, what I do, set up a iis front end for redirect urls.
i.e. if your server name was repos and your domain was mycompany.com then you might set source to repos.mycompany.com:8624/nuget/myrepo and set script source to repos:8624/nuget/myrepo
You can list and publish scripts or modules to the same repo and find-script will differentiate from within the repo.
The more elegant solution, but more difficult, is to create a dummy website with real or virtual paths that use http redirects to the right sight. So you could set your source to something like repos.mycompany.com/source and that folder would redirect to the path on the different port.
That's just a quick summary of the workaround, I realize that, I can provide more thorough examples if you would like.