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

Enable overriding buildkite-agent url in install.ps1 #1805

Merged
merged 1 commit into from
Dec 13, 2023

Conversation

staticfloat
Copy link
Contributor

When using the very helpful buildkite-agent installation powershell script, it is occasionally necessary to install some other version, rather than the current latest release. While it would be cool to support specifying an actual version, the simplest method of this is to simply provide the exact URL to be downloaded. Example invocation:

$env:buildkiteAgentUrl = "https://github.com/buildkite/agent/releases/download/v3.39.0/buildkite-agent-windows-amd64-3.39.0.zip"

iex ((New-Object System.Net.WebClient).DownloadString('https://raw.githubusercontent.com/staticfloat/agent/patch-1/install.ps1'))

staticfloat added a commit to JuliaCI/sandboxed-buildkite-agent that referenced this pull request Oct 25, 2022
This is to work around the issue discussed in [0], and uses the
version-locking mechanism created in [1]

[0]: buildkite/agent#1804
[1]: buildkite/agent#1805
@DrJosh9000 DrJosh9000 self-requested a review November 8, 2022 00:57
@DrJosh9000 DrJosh9000 added the quality of life Little improvements label Jul 19, 2023
When using the very helpful `buildkite-agent` installation powershell script, it is occasionally necessary to install some other version, rather than the current latest release.  While it would be cool to support specifying an actual version, the simplest method of this is to simply provide the exact URL to be downloaded.  Example invocation:

```
$env:buildkiteAgentUrl = "https://github.com/buildkite/agent/releases/download/v3.39.0/buildkite-agent-windows-amd64-3.39.0.zip"

iex ((New-Object System.Net.WebClient).DownloadString('https://raw.githubusercontent.com/buildkite/agent/main/install.ps1'))
```
Copy link
Contributor

@DrJosh9000 DrJosh9000 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for this! Sorry it took a while.

@mwrock
Copy link

mwrock commented Dec 13, 2023

FYI: This merge breaks current calls to https://raw.githubusercontent.com/buildkite/agent/master/install.ps1 when $version is not populated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
quality of life Little improvements
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants