...

Text file src/github.com/googleapis/enterprise-certificate-proxy/.github/workflows/test-signer-linux.yml

Documentation: github.com/googleapis/enterprise-certificate-proxy/.github/workflows

     1name: Build and Test Signer Linux
     2
     3on:
     4  push:
     5    branches: [ main ]
     6  pull_request:
     7    branches: [ main ]
     8
     9jobs:
    10
    11  build:
    12    runs-on: ubuntu-latest
    13    steps:
    14    - uses: actions/checkout@v3
    15
    16    - name: Bootstrap SoftHSM Credentials
    17      run: ./scripts/softhsm_setup.sh
    18
    19    - name: Set up Go
    20      uses: actions/setup-go@v4
    21      with:
    22        go-version: 1.19
    23
    24    - name: Build
    25      working-directory: ./internal/signer/linux
    26      run: go build -v ./...
    27
    28    - name: Test
    29      working-directory: ./internal/signer/linux
    30      run: go test -v ./... -testSlot=$(pkcs11-tool --list-slots --module "/usr/lib/x86_64-linux-gnu/softhsm/libsofthsm2.so" | grep -Eo "0x[A-Fa-f0-9]+" | head -n 1)
    31
    32    - name: Lint
    33      uses: golangci/golangci-lint-action@v3
    34      with:
    35        version: latest
    36        working-directory: ./internal/signer/linux
    37        args: -E gofmt --max-same-issues 0
    38
    39    - name: Create Binaries
    40      run: ./build/scripts/linux_amd64.sh
    41
    42    - uses: actions/upload-artifact@v3
    43      with:
    44        name: linux_amd64
    45        path: ./build/bin/linux_amd64/*

View as plain text