Skip to content
This repository was archived by the owner on Apr 22, 2025. It is now read-only.

Commit b67b27c

Browse files
Use GitHub Actions for PR and scheduled builds (#595)
Signed-off-by: Mark S. Lewis <[email protected]>
1 parent cf2741f commit b67b27c

File tree

2 files changed

+50
-9
lines changed

2 files changed

+50
-9
lines changed

.github/workflows/build.yml

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
name: Build
2+
3+
on:
4+
# push:
5+
# branches: ["release-2.2"]
6+
pull_request:
7+
branches: ["release-2.2"]
8+
schedule:
9+
- cron: "45 23 * * *"
10+
11+
env:
12+
FABRIC_VERSION: 2.2
13+
SOFTHSM2_CONF: ${{ github.workspace }}/test/ts-fixtures/hsm/softhsm2.conf
14+
15+
jobs:
16+
build:
17+
runs-on: ubuntu-20.04
18+
19+
strategy:
20+
fail-fast: false
21+
matrix:
22+
node-version: [10.x, 12.x, 14.x, 16.x]
23+
24+
steps:
25+
- uses: actions/checkout@v3
26+
27+
- name: Use Node.js ${{ matrix.node-version }}
28+
uses: actions/setup-node@v3
29+
with:
30+
node-version: ${{ matrix.node-version }}
31+
32+
- name: Install SoftHSM
33+
run: |
34+
sudo apt-get install softhsm2
35+
softhsm2-util --init-token --slot 0 --label "ForFabric" --pin 98765432 --so-pin 1234
36+
37+
- name: npm install
38+
run: npm install
39+
40+
- name: Generate credentials
41+
run: npm run installAndGenerateCerts
42+
43+
- name: Pull Fabric images
44+
run: npm run pullFabricImages
45+
46+
- name: Run tests
47+
run: npm test

azure-pipelines.yml

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5,19 +5,13 @@
55

66
# Pipeline-level keywords belong here
77

8-
schedules:
9-
- cron: "0 0 * * *" # https://crontab.guru/#0_0_*_*_*
10-
displayName: "Daily midnight build"
11-
branches:
12-
include:
13-
- release-2.2
14-
always: true
15-
168
trigger:
179
- release-2.2
1810

1911
pr:
20-
- release-2.2
12+
branches:
13+
exclude:
14+
- '*'
2115

2216
pool:
2317
vmImage: 'ubuntu-20.04'

0 commit comments

Comments
 (0)