invidious/lib/pg/.circleci/config.yml
Leon Klingele 40fb17791e
shard: track dependencies
Commit the whole ./lib/ folder which stores the Crystal dependencies.
This has a few benefits:

- Allows to build the project without a connection to the Internet
  to retrieve dependencies.
- Makes the project resistant against dependency re-tags which might
  include malicious code.
2019-08-15 01:51:27 +02:00

51 lines
1012 B
YAML

version: 2
testdefault: &testdefault
docker:
- image: crystallang/crystal:latest
steps:
- checkout
- run:
name: postgres setup
command: |
bash .circleci/install.sh
bash .circleci/setup.sh
touch spec/.run_auth_specs
- run: crystal --version
- run: crystal tool format --check
- run: shards install
- run:
name: set DATABASE_URL
command: echo 'export DATABASE_URL=postgres://postgres@localhost/postgres' >> $BASH_ENV
- run: crystal spec --error-on-warnings
noscram: &noscram
environment:
NOSCRAM: true
jobs:
postgresql-11:
<<: *testdefault
postgresql-10:
<<: *testdefault
postgresql-9.6:
<<: *testdefault
<<: *noscram
postgresql-9.5:
<<: *testdefault
<<: *noscram
postgresql-9.4:
<<: *testdefault
<<: *noscram
workflows:
version: 2
ci:
jobs:
- postgresql-11
- postgresql-10
- postgresql-9.6
- postgresql-9.5
- postgresql-9.4