Skip to content

Commit

Permalink
ci: use ubuntu instead of macos
Browse files Browse the repository at this point in the history
  • Loading branch information
microshine committed Jan 30, 2024
1 parent 3d85327 commit acf3445
Showing 1 changed file with 18 additions and 2 deletions.
20 changes: 18 additions & 2 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ on: [push, pull_request]

jobs:
build:
runs-on: macos-latest
runs-on: ubuntu-latest

strategy:
matrix:
Expand All @@ -20,8 +20,22 @@ jobs:

- name: Install SoftHSM
run: |
brew install softhsm
sudo apt-get update -y
sudo apt-get install -y softhsm2
echo "SoftHSM2 is installed"
# Create a configuration file
echo "directories.tokendir = ${{ github.workspace }}/token" > softhsm2.conf
echo "objectstore.backend = file" >> softhsm2.conf
echo "log.level = ERROR" >> softhsm2.conf
echo "slots.removable = false" >> softhsm2.conf
echo "slots.mechanisms = ALL" >> softhsm2.conf
echo "library.reset_on_fork = false" >> softhsm2.conf
# Create a directory for the token
mkdir -p ${{ github.workspace }}/token
# Create a symlink to the SoftHSM library
softhsm2-util --init-token --so-pin "12345" --pin "12345" --slot 0 --label "My slot 0"
env:
SOFTHSM2_CONF: ${{ github.workspace }}/softhsm2.conf

- name: Install NSS
run: brew install nss
Expand All @@ -43,6 +57,8 @@ jobs:

- name: Run test with coverage
run: npm run coverage
env:
SOFTHSM2_CONF: ${{ github.workspace }}/softhsm2.conf

- name: Coveralls
uses: coverallsapp/github-action@v2

0 comments on commit acf3445

Please sign in to comment.