1112 строки
40 KiB
YAML
1112 строки
40 KiB
YAML
parameters:
|
|
- name: tag
|
|
displayName: 'New Release Tag'
|
|
type: string
|
|
default: 'blobfuse2-'
|
|
|
|
- name: unit_test
|
|
displayName: 'Execute Unit Tests'
|
|
type: boolean
|
|
default: false
|
|
|
|
- name: post_release
|
|
displayName: 'Post Release on Github'
|
|
type: boolean
|
|
default: false
|
|
|
|
- name: draft
|
|
displayName: 'Post as Draft Release'
|
|
type: boolean
|
|
default: false
|
|
|
|
- name: prerelease
|
|
displayName: 'Post as PreRelease'
|
|
type: boolean
|
|
default: false
|
|
|
|
- name: update_version
|
|
displayName: 'Update Version'
|
|
type: boolean
|
|
default: false
|
|
|
|
# Do not trigger this pipeline automatically
|
|
trigger: none
|
|
pr: none
|
|
|
|
stages:
|
|
- stage: BuildArtifacts
|
|
jobs:
|
|
- job: Set_1
|
|
timeoutInMinutes: 120
|
|
strategy:
|
|
matrix:
|
|
Libfuse:
|
|
vmImage: 'ubuntu-20.04'
|
|
fuselib: 'libfuse-dev'
|
|
tags: 'fuse2'
|
|
container: 'test-cnt-ubn-18'
|
|
AgentName: "blobfuse-ubuntu20"
|
|
Libfuse3:
|
|
vmImage: 'ubuntu-20.04'
|
|
fuselib: 'libfuse3-dev'
|
|
tags: 'fuse3'
|
|
container: 'test-cnt-ubn-20'
|
|
AgentName: "blobfuse-ubuntu20"
|
|
|
|
pool:
|
|
name: "blobfuse-ubuntu-pool"
|
|
demands:
|
|
- ImageOverride -equals $(AgentName)
|
|
|
|
variables:
|
|
- group: NightlyBlobFuse
|
|
- name: root_dir
|
|
value: '$(System.DefaultWorkingDirectory)'
|
|
- name: work_dir
|
|
value: '$(System.DefaultWorkingDirectory)/azure-storage-fuse'
|
|
|
|
steps:
|
|
- checkout: none
|
|
- script: |
|
|
git clone https://github.com/Azure/azure-storage-fuse
|
|
displayName: 'Checkout Code'
|
|
workingDirectory: $(root_dir)
|
|
|
|
# list commits from past 12hrs
|
|
- script: |
|
|
git checkout `echo $(Build.SourceBranch) | cut -d "/" -f 1,2 --complement`
|
|
git --no-pager log --since="12 hours ago" --stat
|
|
displayName: 'List Commits'
|
|
workingDirectory: $(work_dir)
|
|
|
|
# install dependencies required for compiling blobfuse
|
|
- script: |
|
|
sudo apt-get update --fix-missing
|
|
sudo apt-get install ruby-dev build-essential pkg-config cmake gcc g++ rpm $(fuselib) -y
|
|
sudo gem install fpm -V
|
|
displayName: "Installing Dependencies"
|
|
|
|
# build blobfuse2 and generate binary
|
|
- template: 'azure-pipeline-templates/build-release.yml'
|
|
parameters:
|
|
work_dir: $(work_dir)
|
|
root_dir: $(root_dir)
|
|
unit_test: ${{ parameters.unit_test }}
|
|
tags: $(tags)
|
|
container: $(container)
|
|
|
|
# place the generated binary files & any additional files in appropriate locations
|
|
- script: |
|
|
mkdir -p pkgDir/usr/bin/
|
|
mkdir -p pkgDir/usr/share/blobfuse2/
|
|
cp azure-storage-fuse/blobfuse2 pkgDir/usr/bin/blobfuse2
|
|
cp azure-storage-fuse/bfusemon pkgDir/usr/bin/bfusemon
|
|
cp azure-storage-fuse/setup/baseConfig.yaml pkgDir/usr/share/blobfuse2/
|
|
cp azure-storage-fuse/sampleFileCacheConfig.yaml pkgDir/usr/share/blobfuse2/
|
|
cp azure-storage-fuse/sampleStreamingConfig.yaml pkgDir/usr/share/blobfuse2/
|
|
mkdir -p pkgDir/etc/rsyslog.d
|
|
mkdir -p pkgDir/etc/logrotate.d
|
|
cp azure-storage-fuse/setup/11-blobfuse2.conf pkgDir/etc/rsyslog.d
|
|
cp azure-storage-fuse/setup/blobfuse2-logrotate pkgDir/etc/logrotate.d/blobfuse2
|
|
workingDirectory: $(root_dir)
|
|
displayName: 'Accumulate pkg files'
|
|
|
|
# using fpm tool for packaging of our binary & performing post-install operations
|
|
# for additional information about fpm refer https://fpm.readthedocs.io/en/v1.13.1/
|
|
- script: |
|
|
fpm -s dir -t deb -n blobfuse2 -C pkgDir/ -v `./pkgDir/usr/bin/blobfuse2 --version | cut -d " " -f 3` -d fuse \
|
|
--maintainer "Blobfuse v-Team <blobfusevteam@microsoft.com>" --url "https://github.com/Azure/azure-storage-fuse" \
|
|
--description "An user-space filesystem for interacting with Azure Storage"
|
|
mv ./blobfuse2*.deb ./blobfuse2-`./pkgDir/usr/bin/blobfuse2 --version | cut -d " " -f 3`-$(tags)-x86-64.deb
|
|
cp ./blobfuse2*.deb $(Build.ArtifactStagingDirectory)
|
|
workingDirectory: $(root_dir)
|
|
displayName: 'Make deb Package'
|
|
|
|
- script: |
|
|
fpm -s dir -t rpm -n blobfuse2 -C pkgDir/ -v `./pkgDir/usr/bin/blobfuse2 --version | cut -d " " -f 3` -d fuse \
|
|
--maintainer "Blobfuse v-Team <blobfusevteam@microsoft.com>" --url "https://github.com/Azure/azure-storage-fuse" \
|
|
--description "An user-space filesystem for interacting with Azure Storage"
|
|
mv ./blobfuse2*.rpm ./blobfuse2-`./pkgDir/usr/bin/blobfuse2 --version | cut -d " " -f 3`-$(tags)-x86-64.rpm
|
|
cp ./blobfuse2*.rpm $(Build.ArtifactStagingDirectory)
|
|
workingDirectory: $(root_dir)
|
|
displayName: 'Make rpm Package'
|
|
|
|
- task: PublishBuildArtifacts@1
|
|
inputs:
|
|
artifactName: 'blobfuse2-temp'
|
|
displayName: 'Publish Artifacts'
|
|
# BuildArtifacts end here
|
|
|
|
- stage: TestArtifacts
|
|
dependsOn: BuildArtifacts
|
|
condition: succeeded('BuildArtifacts')
|
|
jobs:
|
|
- job: Set_0
|
|
timeoutInMinutes: 120
|
|
strategy:
|
|
matrix:
|
|
Ubuntu-22:
|
|
agentName: "blobfuse-ubuntu22"
|
|
vmImage: 'Ubuntu-22.04'
|
|
fuse-version: 'fuse3'
|
|
fuselib: 'libfuse3-dev'
|
|
tags: 'fuse3'
|
|
container: 'test-cnt-ubn-22'
|
|
pool:
|
|
vmImage: $(vmImage)
|
|
|
|
variables:
|
|
- group: NightlyBlobFuse
|
|
- name: root_dir
|
|
value: '$(System.DefaultWorkingDirectory)'
|
|
- name: work_dir
|
|
value: '$(System.DefaultWorkingDirectory)/azure-storage-fuse'
|
|
- name: mount_dir
|
|
value: '$(System.DefaultWorkingDirectory)/fusetmp'
|
|
- name: temp_dir
|
|
value: '$(System.DefaultWorkingDirectory)/fusetmpcache'
|
|
|
|
steps:
|
|
- checkout: none
|
|
|
|
- task: GoTool@0
|
|
inputs:
|
|
version: '1.16.2'
|
|
displayName: "GoTool Setup"
|
|
|
|
- script: |
|
|
git clone https://github.com/Azure/azure-storage-fuse
|
|
displayName: 'Checkout Code'
|
|
workingDirectory: $(root_dir)
|
|
|
|
- script: |
|
|
git checkout `echo $(Build.SourceBranch) | cut -d "/" -f 1,2 --complement`
|
|
displayName: 'Checkout Branch'
|
|
workingDirectory: $(root_dir)/azure-storage-fuse
|
|
|
|
- task: DownloadBuildArtifacts@0
|
|
displayName: 'Download Build Artifacts'
|
|
inputs:
|
|
artifactName: 'blobfuse2-temp'
|
|
downloadPath: $(root_dir)
|
|
itemPattern: blobfuse2-temp/blobfuse2*$(tags)*.deb
|
|
|
|
- script: |
|
|
for f in ./blobfuse2*$(tags)*.deb; do mv -v "$f" "${f/-$(tags)-/-$(vmImage)-}"; done;
|
|
cp ./blobfuse2*$(vmImage)*.deb $(Build.ArtifactStagingDirectory)
|
|
displayName: 'Rename Package'
|
|
workingDirectory: $(root_dir)/blobfuse2-temp
|
|
|
|
- script: |
|
|
sudo dpkg --info blobfuse2*.deb
|
|
sudo dpkg -i blobfuse2*.deb
|
|
sudo apt-get install $(fuse-version) build-essential -y
|
|
displayName: 'Install Package'
|
|
workingDirectory: $(Build.ArtifactStagingDirectory)
|
|
|
|
- template: 'azure-pipeline-templates/release-distro-tests.yml'
|
|
parameters:
|
|
root_dir: $(root_dir)
|
|
work_dir: $(work_dir)
|
|
mount_dir: $(mount_dir)
|
|
temp_dir: $(temp_dir)
|
|
container: $(container)
|
|
|
|
# publishing the artifacts generated
|
|
- task: PublishBuildArtifacts@1
|
|
inputs:
|
|
artifactName: 'blobfuse2'
|
|
displayName: 'Publish Artifacts'
|
|
|
|
- job: Set_1
|
|
timeoutInMinutes: 120
|
|
strategy:
|
|
matrix:
|
|
Ubuntu-18:
|
|
vmImage: 'Ubuntu-18.04'
|
|
fuselib: 'libfuse-dev'
|
|
fuse-version: 'fuse'
|
|
tags: 'fuse2'
|
|
container: 'test-cnt-ubn-18'
|
|
AgentName: "blobfuse-ubuntu18"
|
|
Ubuntu-20:
|
|
vmImage: 'Ubuntu-20.04'
|
|
fuse-version: 'fuse3'
|
|
fuselib: 'libfuse3-dev'
|
|
tags: 'fuse3'
|
|
container: 'test-cnt-ubn-20'
|
|
AgentName: "blobfuse-ubuntu20"
|
|
|
|
pool:
|
|
name: "blobfuse-ubuntu-pool"
|
|
demands:
|
|
- ImageOverride -equals $(AgentName)
|
|
|
|
variables:
|
|
- group: NightlyBlobFuse
|
|
- name: root_dir
|
|
value: '$(System.DefaultWorkingDirectory)'
|
|
- name: work_dir
|
|
value: '$(System.DefaultWorkingDirectory)/azure-storage-fuse'
|
|
- name: mount_dir
|
|
value: '$(System.DefaultWorkingDirectory)/fusetmp'
|
|
- name: temp_dir
|
|
value: '$(System.DefaultWorkingDirectory)/fusetmpcache'
|
|
|
|
steps:
|
|
- checkout: none
|
|
|
|
- task: GoTool@0
|
|
inputs:
|
|
version: '1.16.2'
|
|
displayName: "GoTool Setup"
|
|
|
|
- script: |
|
|
git clone https://github.com/Azure/azure-storage-fuse
|
|
displayName: 'Checkout Code'
|
|
workingDirectory: $(root_dir)
|
|
|
|
- script: |
|
|
git checkout `echo $(Build.SourceBranch) | cut -d "/" -f 1,2 --complement`
|
|
displayName: 'Checkout Branch'
|
|
workingDirectory: $(root_dir)/azure-storage-fuse
|
|
|
|
- task: DownloadBuildArtifacts@0
|
|
displayName: 'Download Build Artifacts'
|
|
inputs:
|
|
artifactName: 'blobfuse2-temp'
|
|
downloadPath: $(root_dir)
|
|
itemPattern: blobfuse2-temp/blobfuse2*$(tags)*.deb
|
|
|
|
- script: |
|
|
for f in ./blobfuse2*$(tags)*.deb; do mv -v "$f" "${f/-$(tags)-/-$(vmImage)-}"; done;
|
|
cp ./blobfuse2*$(vmImage)*.deb $(Build.ArtifactStagingDirectory)
|
|
displayName: 'Rename Package'
|
|
workingDirectory: $(root_dir)/blobfuse2-temp
|
|
|
|
- script: |
|
|
sudo dpkg --info blobfuse2*.deb
|
|
sudo dpkg -i blobfuse2*.deb
|
|
sudo apt-get install $(fuse-version) build-essential -y
|
|
displayName: 'Install Package'
|
|
workingDirectory: $(Build.ArtifactStagingDirectory)
|
|
|
|
- template: 'azure-pipeline-templates/release-distro-tests.yml'
|
|
parameters:
|
|
root_dir: $(root_dir)
|
|
work_dir: $(work_dir)
|
|
mount_dir: $(mount_dir)
|
|
temp_dir: $(temp_dir)
|
|
container: $(container)
|
|
|
|
# publishing the artifacts generated
|
|
- task: PublishBuildArtifacts@1
|
|
inputs:
|
|
artifactName: 'blobfuse2'
|
|
displayName: 'Publish Artifacts'
|
|
|
|
- job: Set_2
|
|
timeoutInMinutes: 120
|
|
strategy:
|
|
matrix:
|
|
Debian-9.0:
|
|
agentName: "DEB 9.0"
|
|
vmImage: 'Debian-9.0'
|
|
fuselib: 'libfuse-dev'
|
|
fuse-version: 'fuse'
|
|
tags: 'fuse2'
|
|
container: 'test-cnt-deb-9'
|
|
|
|
pool:
|
|
name: "BlobFuse Pool"
|
|
demands:
|
|
- Agent.Name -equals $(AgentName)
|
|
|
|
variables:
|
|
- group: NightlyBlobFuse
|
|
- name: root_dir
|
|
value: "/home/vsts/workv2"
|
|
- name: work_dir
|
|
value: "/home/vsts/workv2/go/src/azure-storage-fuse"
|
|
- name: mount_dir
|
|
value: "/home/vsts/workv2/blob_mnt"
|
|
- name: temp_dir
|
|
value: "/home/vsts/workv2/blobfuse2tmp"
|
|
|
|
steps:
|
|
- checkout: none
|
|
|
|
- task: GoTool@0
|
|
inputs:
|
|
version: '1.16.2'
|
|
displayName: "GoTool Setup"
|
|
|
|
- script: |
|
|
sudo rm -rf $(root_dir)/azure-storage-fuse
|
|
git clone https://github.com/Azure/azure-storage-fuse
|
|
displayName: 'Checkout Code'
|
|
workingDirectory: $(root_dir)
|
|
|
|
- script: |
|
|
git checkout `echo $(Build.SourceBranch) | cut -d "/" -f 1,2 --complement`
|
|
displayName: 'Checkout Branch'
|
|
workingDirectory: $(root_dir)/azure-storage-fuse
|
|
|
|
- task: DownloadBuildArtifacts@0
|
|
displayName: 'Download Build Artifacts'
|
|
inputs:
|
|
artifactName: 'blobfuse2-temp'
|
|
downloadPath: $(root_dir)
|
|
itemPattern: blobfuse2-temp/blobfuse2*$(tags)*.deb
|
|
|
|
- script: |
|
|
for f in ./blobfuse2*$(tags)*.deb; do mv -v "$f" "${f/-$(tags)-/-$(vmImage)-}"; done;
|
|
cp ./blobfuse2*$(vmImage)*.deb $(Build.ArtifactStagingDirectory)
|
|
displayName: 'Rename Package'
|
|
workingDirectory: $(root_dir)/blobfuse2-temp
|
|
|
|
- script: |
|
|
sudo dpkg --info blobfuse2*.deb
|
|
sudo dpkg -i blobfuse2*.deb
|
|
sudo apt-get install $(fuse-version) build-essential -y
|
|
displayName: 'Install Package'
|
|
workingDirectory: $(Build.ArtifactStagingDirectory)
|
|
|
|
- template: 'azure-pipeline-templates/release-distro-tests.yml'
|
|
parameters:
|
|
root_dir: $(root_dir)
|
|
work_dir: $(work_dir)
|
|
mount_dir: $(mount_dir)
|
|
temp_dir: $(temp_dir)
|
|
container: $(container)
|
|
|
|
# publishing the artifacts generated
|
|
- task: PublishBuildArtifacts@1
|
|
inputs:
|
|
artifactName: 'blobfuse2'
|
|
displayName: 'Publish Artifacts'
|
|
|
|
- job: Set_3
|
|
timeoutInMinutes: 120
|
|
strategy:
|
|
matrix:
|
|
Debian-10.0:
|
|
agentName: "blobfuse-debian10"
|
|
vmImage: 'Debian-10.0'
|
|
fuselib: 'libfuse-dev'
|
|
fuse-version: 'fuse'
|
|
tags: 'fuse2'
|
|
container: 'test-cnt-deb-10'
|
|
Debian-11.0:
|
|
agentName: "blobfuse-debian11"
|
|
vmImage: 'Debian-11.0'
|
|
fuse-version: 'fuse3'
|
|
fuselib: 'libfuse3-dev'
|
|
tags: 'fuse3'
|
|
container: 'test-cnt-deb-11'
|
|
|
|
pool:
|
|
name: "blobfuse-debian-pool"
|
|
demands:
|
|
- ImageOverride -equals $(agentName)
|
|
|
|
variables:
|
|
- group: NightlyBlobFuse
|
|
- name: root_dir
|
|
value: '$(System.DefaultWorkingDirectory)'
|
|
- name: work_dir
|
|
value: '$(System.DefaultWorkingDirectory)/azure-storage-fuse'
|
|
- name: mount_dir
|
|
value: '$(System.DefaultWorkingDirectory)/fusetmp'
|
|
- name: temp_dir
|
|
value: '$(System.DefaultWorkingDirectory)/fusetmpcache'
|
|
|
|
steps:
|
|
- checkout: none
|
|
|
|
- task: GoTool@0
|
|
inputs:
|
|
version: '1.16.2'
|
|
displayName: "GoTool Setup"
|
|
|
|
- script: |
|
|
sudo apt-get update -y
|
|
sudo apt-get install git -y
|
|
displayName: 'Install Git'
|
|
|
|
- script: |
|
|
git clone https://github.com/Azure/azure-storage-fuse
|
|
displayName: 'Checkout Code'
|
|
workingDirectory: $(root_dir)
|
|
|
|
- script: |
|
|
git checkout `echo $(Build.SourceBranch) | cut -d "/" -f 1,2 --complement`
|
|
displayName: 'Checkout Branch'
|
|
workingDirectory: $(root_dir)/azure-storage-fuse
|
|
|
|
- task: DownloadBuildArtifacts@0
|
|
displayName: 'Download Build Artifacts'
|
|
inputs:
|
|
artifactName: 'blobfuse2-temp'
|
|
downloadPath: $(root_dir)
|
|
itemPattern: blobfuse2-temp/blobfuse2*$(tags)*.deb
|
|
|
|
- script: |
|
|
for f in ./blobfuse2*$(tags)*.deb; do mv -v "$f" "${f/-$(tags)-/-$(vmImage)-}"; done;
|
|
cp ./blobfuse2*$(vmImage)*.deb $(Build.ArtifactStagingDirectory)
|
|
displayName: 'Rename Package'
|
|
workingDirectory: $(root_dir)/blobfuse2-temp
|
|
|
|
- script: |
|
|
sudo dpkg --info blobfuse2*.deb
|
|
sudo apt-get install $(fuse-version) build-essential -y
|
|
sudo dpkg -i blobfuse2*.deb
|
|
displayName: 'Install Package'
|
|
workingDirectory: $(Build.ArtifactStagingDirectory)
|
|
|
|
- template: 'azure-pipeline-templates/release-distro-tests.yml'
|
|
parameters:
|
|
root_dir: $(root_dir)
|
|
work_dir: $(work_dir)
|
|
mount_dir: $(mount_dir)
|
|
temp_dir: $(temp_dir)
|
|
container: $(container)
|
|
|
|
# publishing the artifacts generated
|
|
- task: PublishBuildArtifacts@1
|
|
inputs:
|
|
artifactName: 'blobfuse2'
|
|
displayName: 'Publish Artifacts'
|
|
|
|
- job: Set_4
|
|
timeoutInMinutes: 120
|
|
strategy:
|
|
matrix:
|
|
RHEL-7.5:
|
|
agentName: "blobfuse-rhel7_5"
|
|
vmImage: 'RHEL-7.5'
|
|
fuselib: 'fuse3-devel'
|
|
fuse-version: 'fuse3'
|
|
tags: 'fuse3'
|
|
container: 'test-cnt-rhel-75'
|
|
RHEL-7.8:
|
|
agentName: "blobfuse-rhel7_8"
|
|
vmImage: 'RHEL-7.8'
|
|
fuselib: 'fuse3-devel'
|
|
fuse-version: 'fuse3'
|
|
tags: 'fuse3'
|
|
container: 'test-cnt-rhel-78'
|
|
RHEL-8.1:
|
|
agentName: "blobfuse-rhel8_1"
|
|
vmImage: 'RHEL-8.1'
|
|
fuselib: 'fuse fuse3-libs fuse3-devel'
|
|
fuse-version: 'fuse3'
|
|
tags: 'fuse3'
|
|
container: 'test-cnt-rhel-81'
|
|
RHEL-8.2:
|
|
agentName: "blobfuse-rhel8_2"
|
|
vmImage: 'RHEL-8.2'
|
|
fuselib: 'fuse fuse3-libs fuse3-devel'
|
|
fuse-version: 'fuse3'
|
|
tags: 'fuse3'
|
|
container: 'test-cnt-rhel-82'
|
|
RHEL-8.6:
|
|
agentName: "blobfuse-rhel8_6"
|
|
vmImage: 'RHEL-8.6'
|
|
fuselib: 'fuse fuse3-libs fuse3-devel'
|
|
fuse-version: 'fuse3'
|
|
tags: 'fuse3'
|
|
container: 'test-cnt-rhel-86'
|
|
# RHEL-9.0:
|
|
# agentName: "blobfuse-rhel9"
|
|
# vmImage: 'RHEL-9.0'
|
|
# fuselib: 'fuse fuse3-libs fuse3-devel'
|
|
# fuse-version: 'fuse3'
|
|
# tags: 'fuse3'
|
|
# container: 'test-cnt-rhel-9'
|
|
|
|
pool:
|
|
name: "blobfuse-rhel-pool"
|
|
demands:
|
|
- ImageOverride -equals $(agentName)
|
|
|
|
variables:
|
|
- group: NightlyBlobFuse
|
|
- name: root_dir
|
|
value: '$(System.DefaultWorkingDirectory)'
|
|
- name: work_dir
|
|
value: '$(System.DefaultWorkingDirectory)/azure-storage-fuse'
|
|
- name: mount_dir
|
|
value: '$(System.DefaultWorkingDirectory)/fusetmp'
|
|
- name: temp_dir
|
|
value: '$(System.DefaultWorkingDirectory)/fusetmpcache'
|
|
|
|
steps:
|
|
- checkout: none
|
|
|
|
- task: GoTool@0
|
|
inputs:
|
|
version: '1.16.2'
|
|
displayName: "GoTool Setup"
|
|
|
|
- script: |
|
|
sudo touch /etc/yum.repos.d/centos.repo
|
|
sudo sh -c 'echo -e "[centos-extras]\nname=Centos extras - $basearch\nbaseurl=http://mirror.centos.org/centos/7/extras/x86_64\nenabled=1\ngpgcheck=1\ngpgkey=http://centos.org/keys/RPM-GPG-KEY-CentOS-7" > /etc/yum.repos.d/centos.repo'
|
|
condition: or(eq(variables['AgentName'], 'blobfuse-rhel7_5'),eq(variables['AgentName'], 'blobfuse-rhel7_8'))
|
|
displayName: "Update OS mirrors"
|
|
|
|
- script: |
|
|
sudo yum update -y
|
|
sudo yum install git -y
|
|
displayName: 'Install Git'
|
|
|
|
- script: |
|
|
git clone https://github.com/Azure/azure-storage-fuse
|
|
displayName: 'Checkout Code'
|
|
workingDirectory: $(root_dir)
|
|
|
|
- script: |
|
|
git checkout `echo $(Build.SourceBranch) | cut -d "/" -f 1,2 --complement`
|
|
displayName: 'Checkout Branch'
|
|
workingDirectory: $(root_dir)/azure-storage-fuse
|
|
|
|
- task: DownloadBuildArtifacts@0
|
|
displayName: 'Download Build Artifacts'
|
|
inputs:
|
|
artifactName: 'blobfuse2-temp'
|
|
downloadPath: $(root_dir)
|
|
itemPattern: blobfuse2-temp/blobfuse2*$(tags)*.rpm
|
|
|
|
- script: |
|
|
for f in ./blobfuse2*$(tags)*.rpm; do mv -v "$f" "${f/-$(tags)-/-$(vmImage)-}"; done;
|
|
cp ./blobfuse2*$(vmImage)*.rpm $(Build.ArtifactStagingDirectory)
|
|
displayName: 'Rename Package'
|
|
workingDirectory: $(root_dir)/blobfuse2-temp
|
|
|
|
- script: |
|
|
sudo sed -i '/^failovermethod=/d' /etc/yum.repos.d/*.repo
|
|
sudo rpm -qip blobfuse2*.rpm
|
|
sudo yum groupinstall "Development Tools" -y
|
|
if [[ $(agentName) == "blobfuse-rhel7_5" || $(agentName) == "blobfuse-rhel7_8" ]]; then
|
|
sudo yum install fuse fuse3-libs fuse3-devel fuse3 -y
|
|
else
|
|
sudo yum install fuse fuse3-libs fuse3-devel fuse3 -y --nobest --allowerasing
|
|
fi
|
|
sudo rpm -i blobfuse2*.rpm
|
|
displayName: 'Install Package'
|
|
workingDirectory: $(Build.ArtifactStagingDirectory)
|
|
|
|
- template: 'azure-pipeline-templates/release-distro-tests.yml'
|
|
parameters:
|
|
root_dir: $(root_dir)
|
|
work_dir: $(work_dir)
|
|
mount_dir: $(mount_dir)
|
|
temp_dir: $(temp_dir)
|
|
container: $(container)
|
|
|
|
# publishing the artifacts generated
|
|
- task: PublishBuildArtifacts@1
|
|
inputs:
|
|
artifactName: 'blobfuse2'
|
|
displayName: 'Publish Artifacts'
|
|
|
|
- job: Set_5
|
|
timeoutInMinutes: 120
|
|
strategy:
|
|
matrix:
|
|
CentOS-7.9:
|
|
agentName: "blobfuse-centos7"
|
|
vmImage: 'CentOS-7.0'
|
|
fuse-version: 'fuse3'
|
|
tags: 'fuse3'
|
|
container: 'test-cnt-cent-7'
|
|
CentOS-8.5:
|
|
agentName: "blobfuse-centos8"
|
|
vmImage: 'CentOS-8.0'
|
|
fuse-version: 'fuse3'
|
|
tags: 'fuse3'
|
|
container: 'test-cnt-cent-8'
|
|
|
|
pool:
|
|
name: "blobfuse-centos-pool"
|
|
demands:
|
|
- ImageOverride -equals $(agentName)
|
|
|
|
variables:
|
|
- group: NightlyBlobFuse
|
|
- name: root_dir
|
|
value: '$(System.DefaultWorkingDirectory)'
|
|
- name: work_dir
|
|
value: '$(System.DefaultWorkingDirectory)/azure-storage-fuse'
|
|
- name: mount_dir
|
|
value: '$(System.DefaultWorkingDirectory)/fusetmp'
|
|
- name: temp_dir
|
|
value: '$(System.DefaultWorkingDirectory)/fusetmpcache'
|
|
|
|
steps:
|
|
- checkout: none
|
|
|
|
- task: GoTool@0
|
|
inputs:
|
|
version: '1.16.2'
|
|
displayName: "GoTool Setup"
|
|
|
|
- script: |
|
|
sudo sed -i 's/mirrorlist/#mirrorlist/g' /etc/yum.repos.d/CentOS-*
|
|
sudo sed -i 's|baseurl=http://mirror.centos.org|baseurl=http://vault.centos.org|g' /etc/yum.repos.d/CentOS-*
|
|
condition: eq(variables['agentName'], 'blobfuse-centos8')
|
|
displayName: "Update OS mirrors"
|
|
|
|
- script: |
|
|
sudo yum update -y
|
|
sudo yum install git -y
|
|
displayName: 'Install Git'
|
|
|
|
- script: |
|
|
git clone https://github.com/Azure/azure-storage-fuse
|
|
displayName: 'Checkout Code'
|
|
workingDirectory: $(root_dir)
|
|
|
|
- script: |
|
|
git checkout `echo $(Build.SourceBranch) | cut -d "/" -f 1,2 --complement`
|
|
displayName: 'Checkout Branch'
|
|
workingDirectory: $(root_dir)/azure-storage-fuse
|
|
|
|
- task: DownloadBuildArtifacts@0
|
|
displayName: 'Download Build Artifacts'
|
|
inputs:
|
|
artifactName: 'blobfuse2-temp'
|
|
downloadPath: $(root_dir)
|
|
itemPattern: blobfuse2-temp/blobfuse2*$(tags)*.rpm
|
|
|
|
- script: |
|
|
for f in ./blobfuse2*$(tags)*.rpm; do mv -v "$f" "${f/-$(tags)-/-$(vmImage)-}"; done;
|
|
cp ./blobfuse2*$(vmImage)*.rpm $(Build.ArtifactStagingDirectory)
|
|
displayName: 'Rename Package'
|
|
workingDirectory: $(root_dir)/blobfuse2-temp
|
|
|
|
- script: |
|
|
sudo rpm -qip blobfuse2*.rpm
|
|
sudo yum install gcc gcc-c++ make -y
|
|
if [ $(agentName) == "blobfuse-centos8" ]; then
|
|
sudo yum install fuse fuse3 fuse3-devel -y --nobest --allowerasing
|
|
else
|
|
sudo yum install fuse fuse3 fuse3-devel -y
|
|
fi
|
|
sudo rpm -i blobfuse2*.rpm
|
|
displayName: 'Install Package'
|
|
workingDirectory: $(Build.ArtifactStagingDirectory)
|
|
|
|
- template: 'azure-pipeline-templates/release-distro-tests.yml'
|
|
parameters:
|
|
root_dir: $(root_dir)
|
|
work_dir: $(work_dir)
|
|
mount_dir: $(mount_dir)
|
|
temp_dir: $(temp_dir)
|
|
container: $(container)
|
|
|
|
# publishing the artifacts generated
|
|
- task: PublishBuildArtifacts@1
|
|
inputs:
|
|
artifactName: 'blobfuse2'
|
|
displayName: 'Publish Artifacts'
|
|
|
|
- job: Set_6
|
|
timeoutInMinutes: 120
|
|
strategy:
|
|
matrix:
|
|
Oracle-8.1:
|
|
agentName: "blobfuse-oracle81"
|
|
vmImage: 'Oracle-8.1'
|
|
fuselib: 'fuse3 fuse3-devel'
|
|
fuse-version: 'fuse3'
|
|
tags: 'fuse3'
|
|
container: "test-cnt-ora-81"
|
|
|
|
pool:
|
|
name: "blobfuse-oracle-pool"
|
|
demands:
|
|
- ImageOverride -equals $(agentName)
|
|
|
|
variables:
|
|
- group: NightlyBlobFuse
|
|
- name: root_dir
|
|
value: '$(System.DefaultWorkingDirectory)'
|
|
- name: work_dir
|
|
value: '$(System.DefaultWorkingDirectory)/azure-storage-fuse'
|
|
- name: mount_dir
|
|
value: '$(System.DefaultWorkingDirectory)/fusetmp'
|
|
- name: temp_dir
|
|
value: '$(System.DefaultWorkingDirectory)/fusetmpcache'
|
|
|
|
steps:
|
|
- checkout: none
|
|
|
|
- task: GoTool@0
|
|
inputs:
|
|
version: '1.16.2'
|
|
displayName: "GoTool Setup"
|
|
|
|
- script: |
|
|
sudo yum update -y
|
|
sudo yum install git -y
|
|
displayName: 'Install Git'
|
|
|
|
- script: |
|
|
git clone https://github.com/Azure/azure-storage-fuse
|
|
displayName: 'Checkout Code'
|
|
workingDirectory: $(root_dir)
|
|
|
|
- script: |
|
|
git checkout `echo $(Build.SourceBranch) | cut -d "/" -f 1,2 --complement`
|
|
displayName: 'Checkout Branch'
|
|
workingDirectory: $(root_dir)/azure-storage-fuse
|
|
|
|
- task: DownloadBuildArtifacts@0
|
|
displayName: 'Download Build Artifacts'
|
|
inputs:
|
|
artifactName: 'blobfuse2-temp'
|
|
downloadPath: $(root_dir)
|
|
itemPattern: blobfuse2-temp/blobfuse2*$(tags)*.rpm
|
|
|
|
- script: |
|
|
for f in ./blobfuse2*$(tags)*.rpm; do mv -v "$f" "${f/-$(tags)-/-$(vmImage)-}"; done;
|
|
cp ./blobfuse2*$(vmImage)*.rpm $(Build.ArtifactStagingDirectory)
|
|
displayName: 'Rename Package'
|
|
workingDirectory: $(root_dir)/blobfuse2-temp
|
|
|
|
- script: |
|
|
sudo rpm -qip blobfuse2*.rpm
|
|
sudo yum install gcc gcc-c++ make -y
|
|
sudo yum install fuse $(fuse-version) -y --nobest --allowerasing
|
|
sudo rpm -i blobfuse2*.rpm
|
|
displayName: 'Install Package'
|
|
workingDirectory: $(Build.ArtifactStagingDirectory)
|
|
|
|
- template: 'azure-pipeline-templates/release-distro-tests.yml'
|
|
parameters:
|
|
root_dir: $(root_dir)
|
|
work_dir: $(work_dir)
|
|
mount_dir: $(mount_dir)
|
|
temp_dir: $(temp_dir)
|
|
container: $(container)
|
|
|
|
# publishing the artifacts generated
|
|
- task: PublishBuildArtifacts@1
|
|
inputs:
|
|
artifactName: 'blobfuse2'
|
|
displayName: 'Publish Artifacts'
|
|
|
|
- job: Set_7
|
|
timeoutInMinutes: 120
|
|
strategy:
|
|
matrix:
|
|
SUSE-15:
|
|
agentName: "blobfuse-suse15"
|
|
vmImage: 'SUSE-15Gen2'
|
|
fuse-version: 'fuse3'
|
|
tags: 'fuse3'
|
|
container: "test-cnt-suse-15"
|
|
|
|
pool:
|
|
name: "blobfuse-suse-pool"
|
|
demands:
|
|
- ImageOverride -equals $(agentName)
|
|
|
|
variables:
|
|
- group: NightlyBlobFuse
|
|
- name: root_dir
|
|
value: '$(System.DefaultWorkingDirectory)'
|
|
- name: work_dir
|
|
value: '$(System.DefaultWorkingDirectory)/azure-storage-fuse'
|
|
- name: mount_dir
|
|
value: '$(System.DefaultWorkingDirectory)/fusetmp'
|
|
- name: temp_dir
|
|
value: '$(System.DefaultWorkingDirectory)/fusetmpcache'
|
|
|
|
steps:
|
|
- checkout: none
|
|
|
|
- task: GoTool@0
|
|
inputs:
|
|
version: '1.16.2'
|
|
displayName: "GoTool Setup"
|
|
|
|
- script: |
|
|
sudo zypper update -y
|
|
sudo zypper -n install git
|
|
displayName: 'Install Git'
|
|
|
|
- script: |
|
|
git clone https://github.com/Azure/azure-storage-fuse
|
|
displayName: 'Checkout Code'
|
|
workingDirectory: $(root_dir)
|
|
|
|
- script: |
|
|
git checkout `echo $(Build.SourceBranch) | cut -d "/" -f 1,2 --complement`
|
|
displayName: 'Checkout Branch'
|
|
workingDirectory: $(root_dir)/azure-storage-fuse
|
|
|
|
- task: DownloadBuildArtifacts@0
|
|
displayName: 'Download Build Artifacts'
|
|
inputs:
|
|
artifactName: 'blobfuse2-temp'
|
|
downloadPath: $(root_dir)
|
|
itemPattern: blobfuse2-temp/blobfuse2*$(tags)*.rpm
|
|
|
|
- script: |
|
|
for f in ./blobfuse2*$(tags)*.rpm; do mv -v "$f" "${f/-$(tags)-/-$(vmImage)-}"; done;
|
|
cp ./blobfuse2*$(vmImage)*.rpm $(Build.ArtifactStagingDirectory)
|
|
displayName: 'Rename Package'
|
|
workingDirectory: $(root_dir)/blobfuse2-temp
|
|
|
|
- script: |
|
|
sudo rpm -qip blobfuse2*.rpm
|
|
sudo zypper -n install make cmake gcc gcc-c++ fuse fuse3
|
|
wget https://rpmfind.net/linux/opensuse/distribution/leap/15.2/repo/oss/x86_64/fuse3-devel-3.6.1-lp152.1.19.x86_64.rpm
|
|
sudo zypper -n --no-gpg-checks install fuse3-devel-3.6.1-lp152.1.19.x86_64.rpm
|
|
sudo rm fuse3-devel*.rpm
|
|
sudo rpm -i blobfuse2*.rpm
|
|
displayName: 'Install Package'
|
|
workingDirectory: $(Build.ArtifactStagingDirectory)
|
|
|
|
- template: 'azure-pipeline-templates/release-distro-tests.yml'
|
|
parameters:
|
|
root_dir: $(root_dir)
|
|
work_dir: $(work_dir)
|
|
mount_dir: $(mount_dir)
|
|
temp_dir: $(temp_dir)
|
|
container: $(container)
|
|
|
|
# publishing the artifacts generated
|
|
- task: PublishBuildArtifacts@1
|
|
inputs:
|
|
artifactName: 'blobfuse2'
|
|
displayName: 'Publish Artifacts'
|
|
|
|
- job: Set_8
|
|
timeoutInMinutes: 120
|
|
strategy:
|
|
matrix:
|
|
Mariner:
|
|
agentName: "blobfuse-mariner"
|
|
vmImage: 'Mariner'
|
|
fuse-version: 'fuse2'
|
|
tags: 'fuse2'
|
|
container: "test-cnt-mari-1"
|
|
|
|
pool:
|
|
name: "blobfuse-mariner-pool"
|
|
demands:
|
|
- ImageOverride -equals $(agentName)
|
|
|
|
variables:
|
|
- group: NightlyBlobFuse
|
|
- name: root_dir
|
|
value: '$(System.DefaultWorkingDirectory)'
|
|
- name: work_dir
|
|
value: '$(System.DefaultWorkingDirectory)/azure-storage-fuse'
|
|
- name: mount_dir
|
|
value: '$(System.DefaultWorkingDirectory)/fusetmp'
|
|
- name: temp_dir
|
|
value: '$(System.DefaultWorkingDirectory)/fusetmpcache'
|
|
|
|
steps:
|
|
- checkout: none
|
|
|
|
- task: GoTool@0
|
|
inputs:
|
|
version: '1.16.2'
|
|
displayName: "GoTool Setup"
|
|
|
|
- script: |
|
|
sudo yum update -y
|
|
sudo yum install git -y
|
|
displayName: 'Install Git'
|
|
|
|
- script: |
|
|
git clone https://github.com/Azure/azure-storage-fuse
|
|
displayName: 'Checkout Code'
|
|
workingDirectory: $(root_dir)
|
|
|
|
- script: |
|
|
git checkout `echo $(Build.SourceBranch) | cut -d "/" -f 1,2 --complement`
|
|
displayName: 'Checkout Branch'
|
|
workingDirectory: $(root_dir)/azure-storage-fuse
|
|
|
|
- task: DownloadBuildArtifacts@0
|
|
displayName: 'Download Build Artifacts'
|
|
inputs:
|
|
artifactName: 'blobfuse2-temp'
|
|
downloadPath: $(root_dir)
|
|
itemPattern: blobfuse2-temp/blobfuse2*$(tags)*.rpm
|
|
|
|
- script: |
|
|
for f in ./blobfuse2*$(tags)*.rpm; do mv -v "$f" "${f/-$(tags)-/-$(vmImage)-}"; done;
|
|
cp ./blobfuse2*$(vmImage)*.rpm $(Build.ArtifactStagingDirectory)
|
|
displayName: 'Rename Package'
|
|
workingDirectory: $(root_dir)/blobfuse2-temp
|
|
|
|
- script: |
|
|
sudo rpm -qip blobfuse2*.rpm
|
|
sudo tdnf install build-essential fuse fuse-devel -y
|
|
sudo rpm -i blobfuse2*.rpm
|
|
displayName: 'Install Package'
|
|
workingDirectory: $(Build.ArtifactStagingDirectory)
|
|
|
|
- template: 'azure-pipeline-templates/release-distro-tests.yml'
|
|
parameters:
|
|
root_dir: $(root_dir)
|
|
work_dir: $(work_dir)
|
|
mount_dir: $(mount_dir)
|
|
temp_dir: $(temp_dir)
|
|
container: $(container)
|
|
|
|
# publishing the artifacts generated
|
|
- task: PublishBuildArtifacts@1
|
|
inputs:
|
|
artifactName: 'blobfuse2'
|
|
displayName: 'Publish Artifacts'
|
|
# TestArtifacts ends here
|
|
|
|
- stage: ReleaseArtifacts
|
|
dependsOn: TestArtifacts
|
|
condition: succeeded('TestArtifacts')
|
|
jobs:
|
|
- job: ReleaseBlobfuse
|
|
pool:
|
|
vmImage: 'ubuntu-20.04'
|
|
|
|
variables:
|
|
- group: NightlyBlobFuse
|
|
|
|
steps:
|
|
- checkout: none
|
|
|
|
- script: |
|
|
echo ${{ parameters.tag }}
|
|
displayName: 'Tag Name'
|
|
|
|
# download artifacts that need to be published
|
|
- task: DownloadBuildArtifacts@0
|
|
displayName: 'Download Build Artifacts'
|
|
inputs:
|
|
artifactName: 'blobfuse2'
|
|
downloadPath: $(Build.ArtifactStagingDirectory)
|
|
|
|
- script: |
|
|
sudo ls -lRt $(Build.ArtifactStagingDirectory)
|
|
md5sum $(Build.ArtifactStagingDirectory)/blobfuse2/*.deb
|
|
md5sum $(Build.ArtifactStagingDirectory)/blobfuse2/*.rpm
|
|
displayName: 'List Artifacts'
|
|
|
|
- ${{ if eq(parameters.post_release, true) }}:
|
|
# Send images for signing
|
|
- task: SFP.build-tasks.custom-build-task-1.EsrpCodeSigning@1
|
|
displayName: 'ESRP CodeSigning blobfuse2'
|
|
inputs:
|
|
ConnectedServiceName: 'ESRP Code signing blobfuse'
|
|
FolderPath: '$(Build.ArtifactStagingDirectory)/blobfuse2'
|
|
Pattern: '*.rpm, *.deb'
|
|
signConfigType: inlineSignParams
|
|
VerboseLogin: true
|
|
inlineOperation: |
|
|
[
|
|
{
|
|
"KeyCode" : "$(ESRP_BLOBFUSE_KEY_CODE)",
|
|
"OperationCode" : "LinuxSign",
|
|
"Parameters" : {},
|
|
"ToolName" : "sign",
|
|
"ToolVersion" : "1.0"
|
|
}
|
|
]
|
|
# Validate signed images have md5sum changed
|
|
- script: |
|
|
chmod 755 $(Build.ArtifactStagingDirectory)/blobfuse2/*.rpm
|
|
chmod 755 $(Build.ArtifactStagingDirectory)/blobfuse2/*.deb
|
|
rm -rf $(Build.ArtifactStagingDirectory)/blobfuse2/*.md
|
|
mv $(Build.ArtifactStagingDirectory)/blobfuse2/* $(Build.ArtifactStagingDirectory)/
|
|
rm -rf $(Build.ArtifactStagingDirectory)/blobfuse2/
|
|
displayName: 'Make Artifacts executable'
|
|
|
|
- script: |
|
|
sudo ls -lRt $(Build.ArtifactStagingDirectory)
|
|
md5sum $(Build.ArtifactStagingDirectory)/*.deb
|
|
md5sum $(Build.ArtifactStagingDirectory)/*.rpm
|
|
displayName: 'List Signed Artifacts'
|
|
|
|
# Push signed images to artifact directory
|
|
- task: PublishBuildArtifacts@1
|
|
inputs:
|
|
artifactName: 'blobfuse2-signed'
|
|
displayName: 'Publish Signed Artifacts'
|
|
|
|
# add release tags & push to github
|
|
- task: GithubRelease@1
|
|
inputs:
|
|
githubConnection: 'blobfuse-git-rel'
|
|
repositoryName: 'Azure/azure-storage-fuse'
|
|
action: 'edit'
|
|
|
|
target: '$(Build.SourceVersion)'
|
|
tagSource: 'userSpecifiedTag'
|
|
|
|
title: ${{ parameters.tag }}
|
|
tag: ${{ parameters.tag }}
|
|
|
|
assets: |
|
|
$(Build.ArtifactStagingDirectory)/*
|
|
changeLogCompareToRelease: 'lastFullRelease'
|
|
changeLogType: 'commitBased'
|
|
isDraft: ${{ parameters.draft }}
|
|
isPreRelease: ${{ parameters.prerelease }}
|
|
assetUploadMode: replace
|
|
|
|
- stage: UpdateLatestVersion
|
|
dependsOn: ReleaseArtifacts
|
|
condition: succeeded('ReleaseArtifacts')
|
|
jobs:
|
|
- job: UpdateVersion
|
|
pool:
|
|
vmImage: 'ubuntu-20.04'
|
|
variables:
|
|
- group: NightlyBlobFuse
|
|
- name: root_dir
|
|
value: '$(System.DefaultWorkingDirectory)'
|
|
|
|
steps:
|
|
- checkout: none
|
|
|
|
- ${{ if eq(parameters.update_version, true) }}:
|
|
- script: |
|
|
sudo apt-get install python3 -y
|
|
python3 --version
|
|
displayName: 'Installing Python'
|
|
|
|
# download artifacts that need to be published
|
|
- task: DownloadBuildArtifacts@0
|
|
displayName: 'Download Build Artifacts'
|
|
inputs:
|
|
artifactName: 'blobfuse2'
|
|
downloadPath: $(Build.ArtifactStagingDirectory)
|
|
|
|
# install blobfuse2
|
|
- script: |
|
|
cd $(Build.ArtifactStagingDirectory)/blobfuse2
|
|
ls | grep -i ubuntu-20.04
|
|
sudo apt-get install ./`ls | grep -i ubuntu-20.04` -y
|
|
blobfuse2 version
|
|
displayName: 'Installing blobfuse2'
|
|
|
|
- script: |
|
|
wget https://raw.githubusercontent.com/Azure/azure-storage-fuse/`echo $(Build.SourceBranch) | cut -d "/" -f 1,2 --complement`/releaseVersionUpdate.py
|
|
ls -l
|
|
displayName: 'Getting Python script'
|
|
workingDirectory: $(root_dir)
|
|
|
|
- script: |
|
|
python3 releaseVersionUpdate.py "$(VERSION_CNT_SAS_URL)" "`blobfuse2 version`"
|
|
displayName: 'Updating version number'
|
|
workingDirectory: $(root_dir)
|
|
|