ex_trainer/.drone.yml
João Paulo Dubas e7df0322d7
All checks were successful
continuous-integration/drone/push Build is passing
Improve project usage (#6)
1. Ignore unnecessary files, such as `pgcli` log/history, and extra `docker-compose` definitions.
2. Add `Makefile` with common tasks.
3. Add git pre-commit hook to ensure project is always properly formatted.
4. Add [`btree_gist`][0] extension to `postgres`.

Reviewed-on: #6

[0]: https://www.postgresql.org/docs/14/btree-gist.html
2022-04-23 17:15:16 +00:00

37 lines
748 B
YAML

---
kind: pipeline
type: docker
name: test
trigger:
event:
- push
- pull_request
steps:
- name: database healthcheck
image: 'postgres:14.2-alpine'
environment:
PGUSER: postgres
PGPASSWORD: postgres
PGHOST: db
commands:
- while ! pg_isready; do sleep 1; done
- name: test
image: 'elixir:1.13.4'
environment:
MIX_ENV: test
POSTGRES_HOST: db
POSTGRES_USER: postgres
POSTGRES_PASS: postgres
commands:
- mix do local.rebar --force, local.hex --force, deps.get, deps.compile
- mix test --cover --trace --slowest 10
services:
- name: db
image: 'postgres:14.2-alpine'
environment:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres