1 Star 0 Fork 0

Snitro/fabric-sdk-node

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
azure-pipelines.yml 3.09 KB
一键复制 编辑 原始数据 按行查看 历史
Brett Logan 提交于 2020-07-15 07:01 . Use Official CouchDB 3.1 Image (#265)
# Node.js
# Build a general Node.js project with npm.
# Add steps that analyze code, save build artifacts, deploy, and more:
# https://docs.microsoft.com/azure/devops/pipelines/languages/javascript
# Pipeline-level keywords belong here
trigger:
- master
pr:
- master
pool:
vmImage: 'ubuntu-18.04'
variables:
- group: credentials
- group: npm
- name: SOFTHSM2_CONF
value: $(Build.Repository.LocalPath)/test/ts-fixtures/hsm/softhsm2.conf
- name: FABRIC_VERSION
value: 2.2
# A Pipeline contains one or more stages
# A stage is a related collection of jobs. By default stages run sequentially
# A job is a collection of steps run by an agent or server
stages:
- stage: SetupRunTests
displayName: Setup and Run Tests
jobs:
- job: SetupRunTests
displayName: Install Node.js and run tests on
strategy:
matrix:
Node10:
versionSpec: '10.x'
Node12:
versionSpec: '12.x'
steps:
- task: NodeTool@0
inputs:
versionSpec: "$(versionSpec)"
displayName: Install Node.js
- script: |
sudo apt-get install softhsm2
softhsm2-util --init-token --slot 0 --label "ForFabric" --pin 98765432 --so-pin 1234
displayName: Install SoftHSM
- script: npm install
displayName: npm install
- script: npm run installAndGenerateCerts
displayName: Generate credentials
- script: npm run pullFabricImages
displayName: Pull Fabric Images
- script: npm test
displayName: Run tests
- stage: Publish
displayName: Publish Packages and Docs
jobs:
- job: PublishPackages
displayName: Publish npm packages
condition: and(succeeded(), eq(variables['Build.Reason'], 'IndividualCI'))
steps:
- task: NodeTool@0
inputs:
versionSpec: '12.x'
displayName: Install Node.js
- script: npm install
displayName: npm install
- script: npm run compile
displayName: Compile
- script: scripts/ci_scripts/azurePublishNpmPackages.sh
displayName: Publish packages
env:
NPM_TOKEN: "$(NPM)"
PROJECT_DIR: "$(Build.Repository.LocalPath)"
- job: PublishDocs
displayName: Publish API documentation
condition: and(succeeded(), eq(variables['Build.Reason'], 'IndividualCI'))
steps:
- task: NodeTool@0
inputs:
versionSpec: '12.x'
displayName: Install Node.js
- script: npm install
displayName: npm install
- script: npm run compile
displayName: Compile
- script: scripts/ci_scripts/azurePublishApiDocs.sh
displayName: Publish API docs
env:
GITHUB_USER: 'Hyperledger Bot'
GITHUB_EMAIL: 'hlfdev.azp@gmail.com'
PUBLISH_URL: "https://$(GITHUB-PAT)@github.com/hyperledger/fabric-sdk-node.git"
PROJECT_DIR: "$(Build.Repository.LocalPath)"
STAGING_DIR: "$(Build.StagingDirectory)/gh-pages"
SOURCE_BRANCH: "$(Build.SourceBranchName)"
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/snitro/fabric-sdk-node.git
git@gitee.com:snitro/fabric-sdk-node.git
snitro
fabric-sdk-node
fabric-sdk-node
master

搜索帮助