Merge pull request #13517 from max-arnold/fix-salt-bootstrap

Fix Salt bootstrap script URLs
This commit is contained in:
Chris Roberts 2024-11-01 12:14:48 -07:00 committed by GitHub
commit d43f154032
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -8,9 +8,9 @@ require_relative "./errors"
module VagrantPlugins
module Salt
class BootstrapDownloader
WINDOWS_URL = "https://winbootstrap.saltproject.io"
URL = "https://bootstrap.saltproject.io"
SHA256_SUFFIX = "sha256"
WINDOWS_URL = "https://github.com/saltstack/salt-bootstrap/releases/latest/download/bootstrap-salt.ps1"
URL = "https://github.com/saltstack/salt-bootstrap/releases/latest/download/bootstrap-salt.sh"
SHA256_SUFFIX = ".sha256"
def initialize(guest)
@guest = guest
@ -32,8 +32,8 @@ module VagrantPlugins
end
def verify_sha256(script)
@logger.debug "Downloading sha256 file from #{source_url}/#{SHA256_SUFFIX}"
sha256_file = download("#{source_url}/#{SHA256_SUFFIX}")
@logger.debug "Downloading sha256 file from #{source_url}#{SHA256_SUFFIX}"
sha256_file = download("#{source_url}#{SHA256_SUFFIX}")
sha256 = extract_sha256(sha256_file.read)
sha256_file.close