Skip to content

Commit

Permalink
general CGO_ENABLED environ
Browse files Browse the repository at this point in the history
  • Loading branch information
fmartingr committed Feb 4, 2024
1 parent 4d493b8 commit 3ca7727
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions .github/workflows/_test.yml
Expand Up @@ -2,6 +2,9 @@ name: "Unit Tests"

on: workflow_call

env:
CGO_ENABLED: 0

jobs:
test-linux:
runs-on: ubuntu-latest
Expand Down Expand Up @@ -54,7 +57,7 @@ jobs:
SHIORI_TEST_PG_URL: "postgres://shiori:shiori@localhost:5432/shiori?sslmode=disable"
SHIORI_TEST_MYSQL_URL: "shiori:shiori@(localhost:3306)/shiori"

- run: CGO_ENABLED=0 go build -tags osusergo,netgo -ldflags="-s -w -X main.version=$(git describe --tags) -X main.date=$(date --iso-8601=seconds)"
- run: go build -tags osusergo,netgo -ldflags="-s -w -X main.version=$(git describe --tags) -X main.date=$(date --iso-8601=seconds)"

- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@4fe8c5f003fae66aa5ebb77cfd3e7bfbbda0b6b0 # 3.1.5
Expand Down Expand Up @@ -84,7 +87,7 @@ jobs:
restore-keys: |
golangci-lint.cache-{interval_number}-
golangci-lint.cache-
env:
CGO_ENABLED: 0
- run: make unittest GO_TEST_FLAGS="-tags test_sqlite_only"
- run: go build -tags osusergo,netgo -ldflags="-s -w -X main.version=$(git describe --tags) -X main.date=$(date --iso-8601=seconds)"

- run: go build -tags osusergo,netgo -ldflags="-s -w -X main.version=$(git describe --tags) -X main.date=$(date --iso-8601=seconds)"

0 comments on commit 3ca7727

Please sign in to comment.