-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathTaskfile.yml
55 lines (47 loc) · 1.19 KB
/
Taskfile.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
47
48
49
50
51
52
53
54
55
version: 3
dotenv:
- ".env"
tasks:
server:
desc: Start the server receiving data
env:
TEACUP_DB_USER: teacup
TEACUP_DB_PW: teacup
cmds:
- cargo run --bin server
server-release:
desc: Start the server receiving monitoring data in release mode
env:
TEACUP_DB_USER: teacup
TEACUP_DB_PW: teacup
cmds:
- cargo run --bin server --release
client:
desc: Start the client sending telemetry
env:
TEACUP_TOKEN: pewpew
cmds:
- cargo run --bin client
client-release:
desc: Start the client sending telemetry in release mode
env:
TEACUP_TOKEN: pewpew
cmds:
- cargo run --bin client --release
setup-db:
desc: Runs the database migration scripts such as creating tables
dir: server
cmds:
# allow longer timeout since by default 10 is a bit short for docker
- sqlx database create --connect-timeout 30
- sqlx migrate run
start-localsetup:
desc: Setup the local environment
cmds:
- docker-compose up -d
- task: setup-db
stop-localsetup:
desc: Stop the local environment
cmds:
- docker-compose down
- docker volume rm teacup_teacup-db-data