bitque/.builds/server.yml

31 lines
794 B
YAML
Raw Normal View History

2020-05-01 22:21:28 +02:00
image: archlinux
2020-05-01 21:40:32 +02:00
packages:
- postgresql
2020-05-01 22:21:28 +02:00
- rustup
2020-05-01 21:40:32 +02:00
sources:
- https://git.sr.ht/~tsumanu/jirs
environment:
deploy: adrian.wozniak@ita-prog.pl
secrets:
- 7ebab768-e5e4-4c9d-ba57-ec41a72c5665
tasks:
2020-05-01 22:21:28 +02:00
- build_config: |
cd jirs/jirs-server
echo 'concurrency = 2' >> db.test.toml
echo 'database_url = "postgres://postgres@localhost:5432/jirs_test"' >> db.test.toml
2020-05-01 21:40:32 +02:00
- setup: |
sudo systemctl start postgresql
2020-05-01 22:21:28 +02:00
rustup toolchain install nightly
rustup default nightly
2020-05-01 21:40:32 +02:00
cargo install diesel_cli --no-default-features --features postgres
cd jirs/jirs-server
diesel migration run
- test: |
cd jirs/jirs-server
cargo test --bin jirs_server
- build: |
cd jirs
cargo build --all --release
- deploy: |
cd jirs