зеркало из
1
0
Форкнуть 0
fluentd-plugin-mdsd/OneBranch.Official.yml

107 строки
4.3 KiB
YAML

schedules:
- cron: "0 0 * * TUESDAY"
displayName: CodeQL weekly scan
branches:
include:
- master
always: true
#################################################################################
# Onebranch Pipelines - Official Linux (CDPXMigrated) #
# This pipeline was created by EasyStart from a sample located at: #
# https://aka.ms/obpipelines/easystart/samples #
# Documentation: https://aka.ms/obpipelines #
# Yaml Schema: https://aka.ms/obpipelines/yaml/schema #
# Retail Tasks: https://aka.ms/obpipelines/tasks #
# Support: https://aka.ms/onebranchsup #
#################################################################################
trigger:
- master
parameters: # parameters are shown up in ADO UI in a build queue time
- name: 'debug'
displayName: 'Enable debug output'
type: boolean
default: false
variables:
CDP_DEFINITION_BUILD_COUNT: $[counter('', 0)] # needed for onebranch.pipeline.version task https://aka.ms/obpipelines/versioning
# Docker image which is used to build the project https://aka.ms/obpipelines/containers
# Image used in CDPX build: cdpxlinux.azurecr.io/global/ubuntu-1804-all:1.0
LinuxContainerImage: 'mcr.microsoft.com/onebranch/cbl-mariner/build:2.0'
DEBIAN_FRONTEND: noninteractive
ROOT: $(Build.SourcesDirectory)
REPOROOT: $(Build.SourcesDirectory)
OUTPUTROOT: $(REPOROOT)\out
CDP_USER_SOURCE_FOLDER_CONTAINER_PATH: $(Build.SourcesDirectory)
CDP_DEFINITION_BUILD_COUNT_DAY: $[counter(format('{0:yyyyMMdd}', pipeline.startTime), 1)]
CDP_DEFINITION_BUILD_COUNT_MONTH: $[counter(format('{0:yyyyMM}', pipeline.startTime), 1)]
CDP_DEFINITION_BUILD_COUNT_YEAR: $[counter(format('{0:yyyy}', pipeline.startTime), 1)]
resources:
repositories:
- repository: templates
type: git
name: OneBranch.Pipelines/GovernedTemplates
ref: refs/heads/main
extends:
template: v2/OneBranch.Official.CrossPlat.yml@templates # https://aka.ms/obpipelines/templates
parameters:
# featureFlags:
# linuxEsrpSigningPreview: true
cloudvault: # https://aka.ms/obpipelines/cloudvault
enabled: true # set to true to enable cloudvault
runmode: stage # linux can run CloudVault upload as a separate stage
dependsOn: linux_stage
artifacts:
- drop
globalSdl: # https://aka.ms/obpipelines/sdl
tsa:
enabled: true # SDL results of non-official builds aren't uploaded to TSA by default.
credscan:
suppressionsFile: $(Build.SourcesDirectory)\CredScanSuppressions.json
policheck:
break: true # always break the build on policheck issues. You can disable it by setting to 'false'
exclusionsFile: $(Build.SourcesDirectory)\PolicheckExclusion.xml
baseline:
baselineFile: $(Build.SourcesDirectory)\global.gdnbaselines
suppression:
suppressionFile: $(Build.SourcesDirectory)\global.gdnsuppress
cg:
ignoreDirectories: azure-linux-extensions/OpenCensusAgent,rsyslog-legacy
codeql:
enabled: true
excludePathPatterns: "$(Build.SourcesDirectory)/azure-linux-extensions/TestHandlerLinux"
stages:
- stage: linux_stage
jobs:
- job: linux_job
pool:
type: linux
variables: # More settings at https://aka.ms/obpipelines/yaml/jobs
ob_outputDirectory: '$(Build.SourcesDirectory)/out' # this directory is uploaded to pipeline artifacts, reddog and cloudvault. More info at https://aka.ms/obpipelines/artifacts
ob_artifactBaseName: 'drop'
steps:
- task: CmdLine@2
displayName: 'Build'
inputs:
script: |
tdnf -y -q upgrade
tdnf -y -q install ca-certificates libyaml libedit libxcrypt util-linux tar sudo git build-essential ruby cmake boost-devel boost-static swig python3-pip cyrus-sasl
update-alternatives --install /usr/bin/python python /usr/bin/python3.9 2
cd src
sed -i /^ParseGlibcVer$/d ./buildall.sh
sed -i /^BuildWithMake\ debpkg$/d ./buildall.sh
./buildall.sh -o -t system
workingDirectory: '$(Build.SourcesDirectory)'