forked from TrueCloudLab/rclone
build: make azure pipelines stop if installs fail
This commit is contained in:
parent
c2050172aa
commit
6929f5d6e6
1 changed files with 9 additions and 1 deletions
|
@ -100,6 +100,7 @@ steps:
|
||||||
echo "##vso[task.setvariable variable=GO_LATEST]true"
|
echo "##vso[task.setvariable variable=GO_LATEST]true"
|
||||||
echo "Latest Go version: $latestGo"
|
echo "Latest Go version: $latestGo"
|
||||||
condition: eq( variables['GO_VERSION'], 'latest' )
|
condition: eq( variables['GO_VERSION'], 'latest' )
|
||||||
|
continueOnError: false
|
||||||
displayName: "Get latest Go version"
|
displayName: "Get latest Go version"
|
||||||
|
|
||||||
- bash: |
|
- bash: |
|
||||||
|
@ -110,13 +111,14 @@ steps:
|
||||||
shopt -s extglob
|
shopt -s extglob
|
||||||
shopt -s dotglob
|
shopt -s dotglob
|
||||||
mv !(gopath) '$(modulePath)'
|
mv !(gopath) '$(modulePath)'
|
||||||
|
continueOnError: false
|
||||||
displayName: Remove old Go, set GOBIN/GOROOT, and move project into GOPATH
|
displayName: Remove old Go, set GOBIN/GOROOT, and move project into GOPATH
|
||||||
|
|
||||||
- task: CacheBeta@0
|
- task: CacheBeta@0
|
||||||
continueOnError: true
|
|
||||||
inputs:
|
inputs:
|
||||||
key: go-build-cache | "$(Agent.JobName)"
|
key: go-build-cache | "$(Agent.JobName)"
|
||||||
path: $(GOCACHE)
|
path: $(GOCACHE)
|
||||||
|
continueOnError: true
|
||||||
displayName: Cache go build
|
displayName: Cache go build
|
||||||
condition: ne( variables['GOCACHE'], '' )
|
condition: ne( variables['GOCACHE'], '' )
|
||||||
|
|
||||||
|
@ -128,6 +130,7 @@ steps:
|
||||||
sudo chown root:$USER /etc/fuse.conf
|
sudo chown root:$USER /etc/fuse.conf
|
||||||
sudo apt-get install fuse libfuse-dev rpm pkg-config
|
sudo apt-get install fuse libfuse-dev rpm pkg-config
|
||||||
condition: eq( variables['Agent.OS'], 'Linux' )
|
condition: eq( variables['Agent.OS'], 'Linux' )
|
||||||
|
continueOnError: false
|
||||||
displayName: Install Libraries on Linux
|
displayName: Install Libraries on Linux
|
||||||
|
|
||||||
- bash: |
|
- bash: |
|
||||||
|
@ -135,6 +138,7 @@ steps:
|
||||||
brew tap caskroom/cask
|
brew tap caskroom/cask
|
||||||
brew cask install osxfuse
|
brew cask install osxfuse
|
||||||
condition: eq( variables['Agent.OS'], 'Darwin' )
|
condition: eq( variables['Agent.OS'], 'Darwin' )
|
||||||
|
continueOnError: false
|
||||||
displayName: Install Libraries on macOS
|
displayName: Install Libraries on macOS
|
||||||
|
|
||||||
- powershell: |
|
- powershell: |
|
||||||
|
@ -150,6 +154,7 @@ steps:
|
||||||
$path = (get-command mingw32-make.exe).Path
|
$path = (get-command mingw32-make.exe).Path
|
||||||
Copy-Item -Path $path -Destination (Join-Path (Split-Path -Path $path) 'make.exe')
|
Copy-Item -Path $path -Destination (Join-Path (Split-Path -Path $path) 'make.exe')
|
||||||
condition: eq( variables['Agent.OS'], 'Windows_NT' )
|
condition: eq( variables['Agent.OS'], 'Windows_NT' )
|
||||||
|
continueOnError: false
|
||||||
displayName: Install Libraries on Windows
|
displayName: Install Libraries on Windows
|
||||||
|
|
||||||
|
|
||||||
|
@ -161,12 +166,14 @@ steps:
|
||||||
sudo chown ${USER}:${USER} $(gorootDir)
|
sudo chown ${USER}:${USER} $(gorootDir)
|
||||||
tar -C $(gorootDir) -xzf "$(GO_VERSION).linux-$(GO_INSTALL_ARCH).tar.gz"
|
tar -C $(gorootDir) -xzf "$(GO_VERSION).linux-$(GO_INSTALL_ARCH).tar.gz"
|
||||||
condition: eq( variables['Agent.OS'], 'Linux' )
|
condition: eq( variables['Agent.OS'], 'Linux' )
|
||||||
|
continueOnError: false
|
||||||
displayName: Install Go on Linux
|
displayName: Install Go on Linux
|
||||||
|
|
||||||
- bash: |
|
- bash: |
|
||||||
wget "https://dl.google.com/go/$(GO_VERSION).darwin-$(GO_INSTALL_ARCH).tar.gz"
|
wget "https://dl.google.com/go/$(GO_VERSION).darwin-$(GO_INSTALL_ARCH).tar.gz"
|
||||||
sudo tar -C $(gorootDir) -xzf "$(GO_VERSION).darwin-$(GO_INSTALL_ARCH).tar.gz"
|
sudo tar -C $(gorootDir) -xzf "$(GO_VERSION).darwin-$(GO_INSTALL_ARCH).tar.gz"
|
||||||
condition: eq( variables['Agent.OS'], 'Darwin' )
|
condition: eq( variables['Agent.OS'], 'Darwin' )
|
||||||
|
continueOnError: false
|
||||||
displayName: Install Go on macOS
|
displayName: Install Go on macOS
|
||||||
|
|
||||||
- powershell: |
|
- powershell: |
|
||||||
|
@ -176,6 +183,7 @@ steps:
|
||||||
Write-Host "Extracting Go"
|
Write-Host "Extracting Go"
|
||||||
Expand-Archive "$(GO_VERSION).windows-$(GO_INSTALL_ARCH).zip" -DestinationPath "$(gorootDir)"
|
Expand-Archive "$(GO_VERSION).windows-$(GO_INSTALL_ARCH).zip" -DestinationPath "$(gorootDir)"
|
||||||
condition: eq( variables['Agent.OS'], 'Windows_NT' )
|
condition: eq( variables['Agent.OS'], 'Windows_NT' )
|
||||||
|
continueOnError: false
|
||||||
displayName: Install Go on Windows
|
displayName: Install Go on Windows
|
||||||
|
|
||||||
# Display environment for debugging
|
# Display environment for debugging
|
||||||
|
|
Loading…
Reference in a new issue