Skip to content

Instantly share code, notes, and snippets.

@Wesley-Lomax
Last active May 10, 2016 15:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Wesley-Lomax/e5c6ea1cc4663a4d37f1 to your computer and use it in GitHub Desktop.
Save Wesley-Lomax/e5c6ea1cc4663a4d37f1 to your computer and use it in GitHub Desktop.
Sitecore Ship Install TDS Update package with CURL
$ConnectionTimeOutInSeconds = 300
$MaxTimeOutInSeconds = 900
$siteHostName = $OctopusParameters["Your.SiteName.Parameter"]
$fileUploadUrl = "http://$siteHostName/services/package/install/fileupload"
$curlPath = "C:\Tools\curl-7.48\bin\curl.exe"
$releaseNumber = $OctopusParameters["Octopus.Release.Number"]
$environment = $OctopusParameters["Octopus.Environment.Name"]
$updatePackagePath = "C:\Octopus\Applications\$environment\RCN.TDS.UpdatePackage\$releaseNumber\RCN.TDS.update"
$curlCommand= "$curlPath --show-error --silent --connect-timeout $ConnectionTimeOutInSeconds --max-time $MaxTimeOutInSeconds --form ""filename=@$updatePackagePath"" $fileUploadUrl"
Write-Output "INFO: Starting Invoke-Expression: $curlCommand"
Invoke-Expression $curlCommand
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment