-
Notifications
You must be signed in to change notification settings - Fork 19
46 lines (41 loc) · 1.01 KB
/
go.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
name: Go
on:
push:
branches: [main]
pull_request:
branches: [main]
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
container: golang:1.21-bullseye
defaults:
run:
shell: bash # needed for codecov
services:
postgres:
image: postgres
env:
POSTGRES_PASSWORD: f1refly
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Fetch history # See https://github.com/actions/checkout/issues/477
run: |-
git config --global --add safe.directory $PWD
git fetch origin
- name: Build and Test
env:
TEST_FLAGS: -v
POSTGRES_HOSTNAME: postgres
POSTGRES_PASSWORD: f1refly
POSTGRES_PORT: 5432
run: make
- name: Upload coverage
run: bash <(curl -s https://codecov.io/bash)