This commit is contained in:
Brandon Waterloo [MSFT] 2024-02-05 12:28:51 -05:00 коммит произвёл GitHub
Родитель 78c8af2f6a
Коммит af383269e9
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: B5690EEEBB952194
2 изменённых файлов: 12 добавлений и 80 удалений

Просмотреть файл

@ -3,7 +3,8 @@ trigger:
- main
- rel/*
pr: none # Disable PR trigger
# Disable PR trigger
pr: none
# Scheduled nightly build
schedules:
@ -14,38 +15,26 @@ schedules:
include:
- main
# The `resources` specify the location and version of the 1ES PT.
# `resources` specifies the location of templates to pick up, use it to get 1ES and AzExt templates
resources:
repositories:
- repository: 1esPipelines
type: git
name: 1ESPipelineTemplates/1ESPipelineTemplates
ref: refs/tags/release
- repository: azExtTemplates
type: github
name: microsoft/vscode-azuretools
ref: main
endpoint: GitHub-AzureTools # The service connection to use when accessing this repository
extends:
# The pipeline extends the 1ES PT which will inject different SDL and compliance tasks.
# For non-production pipelines, use "Unofficial" as defined below.
# For productions pipelines, use "Official".
template: v1/1ES.Official.PipelineTemplate.yml@1esPipelines
parameters:
# Update the pool with your team's 1ES hosted pool.
pool:
name: Azure Pipelines # Name of your hosted pool
image: windows-latest # Name of the image in your pool. If not specified, first image of the pool is used
name: VSEngSS-MicroBuild2022-1ES # Name of your hosted pool
image: server2022-microbuildVS2022-1es # Name of the image in your pool. If not specified, first image of the pool is used
os: windows # OS of the image. Allowed values: windows, linux, macOS
stages:
- stage: Stage
jobs:
- job: HostJob
# If the pipeline publishes artifacts, use `templateContext` to define the artifacts.
# This will enable 1ES PT to run SDL analysis tools on the artifacts and then upload them.
templateContext:
outputs:
- output: pipelineArtifact
targetPath: $(System.DefaultWorkingDirectory)/Samples
artifactName: artifactName
# Define the steps that the pipeline will run.
# In most cases, copy and paste the steps from the original pipeline.
steps:
- powershell: echo "Hello World from host"
# Execute stages from the AzExt template
- template: azure-pipelines/1esjobs.yml@azExtTemplates

Просмотреть файл

@ -1,57 +0,0 @@
stages:
- stage: build
jobs:
- job: main
pool:
type: windows
name: OneBranchPipelines
variables:
ob_outputDirectory: $(Build.ArtifactStagingDirectory)\output
WindowsContainerImage: onebranch.azurecr.io/windows/ltsc2019/vse2022:latest
steps:
- task: NodeTool@0
displayName: Using Node.js
inputs:
versionSource: fromFile
versionFilePath: .nvmrc
- task: Npm@1
displayName: Install Dependencies
inputs:
command: custom
customCommand: ci --no-optional
- bash: |
/usr/bin/Xvfb :99 -screen 0 1024x768x24 > /dev/null 2>&1 &
echo ">>> Started xvfb"
displayName: Start X Virtual Frame Buffer
condition: and(succeeded(), eq(variables['Agent.OS'], 'Linux'))
- task: Npm@1
displayName: "Build"
inputs:
command: custom
customCommand: run build
- task: Npm@1
displayName: "Package"
inputs:
command: custom
customCommand: run package
- task: CopyFiles@2
displayName: "Copy packages and vsix to staging directory"
inputs:
Contents: |
**/*.vsix
**/*.tar.gz
**/*.tgz
TargetFolder: "$(build.artifactstagingdirectory)/build"
condition: and(eq(variables['Agent.OS'], 'Linux'), ne(variables['System.PullRequest.IsFork'], 'True'))
- task: PublishBuildArtifacts@1
displayName: "Publish artifacts: packages and vsix"
inputs:
PathtoPublish: "$(build.artifactstagingdirectory)/build"
ArtifactName: $(artifact_name)
condition: and(eq(variables['Agent.OS'], 'Linux'), ne(variables['System.PullRequest.IsFork'], 'True'))