Skip to content

Commit f80231c

Browse files
committed
ci: Migrate to Github Actions
1 parent dcd7f29 commit f80231c

File tree

3 files changed

+16
-46
lines changed

3 files changed

+16
-46
lines changed

.github/workflows/build.yml

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,22 @@
11
name: Build and Test
2-
on: [push]
2+
on:
3+
push:
4+
branches:
5+
- master
36
jobs:
47
test:
58
name: Test
69
runs-on: ubuntu-latest
10+
services:
11+
postgres:
12+
image: postgres:11.5
13+
env:
14+
POSTGRES_USER: postgres
15+
POSTGRES_PASSWORD: postgres
16+
POSTGRES_DB: postgres
17+
ports:
18+
- 5432/tcp
19+
options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5
720
steps:
821
- name: Set up Golang
922
uses: actions/setup-go@v1
@@ -15,3 +28,5 @@ jobs:
1528

1629
- name: Run unit tests
1730
run: make test
31+
env:
32+
CTF_DB_DSN: 'postgres://postgres:postgres@localhost:5432/postgres_test?sslmode=disable'

.github/workflows/build2.yml

Lines changed: 0 additions & 17 deletions
This file was deleted.

.travis.yml

Lines changed: 0 additions & 28 deletions
This file was deleted.

0 commit comments

Comments
 (0)