Add cmdlet to download artifact
New-OctopusArtifact allows you to attach an artifact to a release. If you wanted to use that same artifact in another step on the same deployment, you'd need to use the API.
It might not be such a bad idea to have a
Get-OctopusArtifact cmdlet that returns info about that artifact, as well as a
Download() method the download the full file from a Tentacle.
Woric Faithfull commented
Totally agree. I need exactly this functionality to send an artifact to DevOps.
To be honest, I was surprised the functionality wasn't provided. (One other user described as 'insanely frustrating', which it is)
P.S. I would be just as happy with New-OctopusArtifact returning the location of the artifact so I can output it in the log.
I need to examine the content of the artifact, however calling the API after creation even with a delay does not seem to work so having a cmdlet will be great!
Tim Cartwright commented
I would love to get the url to the artifact for embedding in emails. This is insanely frustrating.
Richie Lee commented
This is an excellent idea: in the case of SQL Server, we publish a diff script as an artifact. If we want to execute the same script, it makes sense to run something like "Get-Artifact" rather than having to do something convoluted.