-
Notifications
You must be signed in to change notification settings - Fork 12
Expand file tree
/
Copy pathTaskfile.yml
More file actions
73 lines (64 loc) · 1.99 KB
/
Copy pathTaskfile.yml
File metadata and controls
73 lines (64 loc) · 1.99 KB
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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
version: '3'
vars:
TAG: dev
IMAGE: pysergio/chibi
tasks:
build:base:
desc: "Build base amd64 and arm64 images in cloud with specified tag"
cmds:
- docker buildx build
--builder cloud-builder
--platform linux/amd64,linux/arm64
--cache-to type=registry,ref={{.IMAGE}}:buildcache,mode=max
--cache-from type=registry,ref={{.IMAGE}}:buildcache
-t {{.IMAGE}}:{{.TAG}}
-f Dockerfile
--push .
build:agent:
desc: "Build agent amd64 and arm64 images in cloud with specified tag"
cmds:
- docker buildx build
--builder cloud-builder
--platform linux/amd64,linux/arm64
--cache-to type=registry,ref={{.IMAGE}}:buildcache,mode=max
--cache-from type=registry,ref={{.IMAGE}}:buildcache
-t {{.IMAGE}}:agent-{{.TAG}}
-f agent.Dockerfile
--push .
build:lbase:
desc: "Build base amd64 and arm64 images locally with specified tag"
cmds:
- docker buildx build
--platform linux/amd64,linux/arm64
-t {{.IMAGE}}:{{.TAG}}
-f Dockerfile
--push .
build:lagent:
desc: "Build agent amd64 and arm64 images locally with specified tag"
cmds:
- docker buildx build
--platform linux/amd64,linux/arm64
-t {{.IMAGE}}:agent-{{.TAG}}
-f agent.Dockerfile
--push .
lint:
desc: "Run linters: ruff format, ruff check --fix, and mypy"
cmds:
- ruff format .
- ruff check --fix .
- mypy .
test:
desc: "Run tests"
cmds:
- pytest -vv .
checks:
desc: "Run linters + tests"
cmds:
- task lint
- task test
update:
desc: "Update dependencies and export deps to the requirements.txt/requirements-dev.txt files"
cmds:
- poetry update
- poetry export -f requirements.txt --output requirements.txt --without-hashes
- poetry export --with dev -f requirements.txt --output requirements-dev.txt --without-hashes