forked from agntcy/slim
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathTaskfile.yaml
More file actions
128 lines (109 loc) · 3.24 KB
/
Taskfile.yaml
File metadata and controls
128 lines (109 loc) · 3.24 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
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
# Copyright AGNTCY Contributors (https://github.com/agntcy)
# SPDX-License-Identifier: Apache-2.0
---
version: '3'
silent: true
set: [pipefail]
shopt: [globstar]
includes:
data-plane:
taskfile: ../tasks/rust.yaml
vars:
GLOBAL_ARGS: "--workspace"
vars:
CARGO_COMPONENTS: "cargo-sort cargo-audit cargo-llvm-cov cargo-machete cargo-deny typos-cli"
tasks:
data-plane:bindings:lint:
desc: "Python linter"
internal: true
dir: ./bindings/python
cmds:
- task python:bindings:lint
data-plane:lint:
desc: "Run the linter"
cmds:
- task: data-plane:lintall
- task: data-plane:bindings:lint
data-plane:build:strip:
desc: "Build the project and strip the debug symbols"
cmds:
- task: data-plane:build
- task: data-plane:strip
vars:
TARGET_BIN: "target/{{.TARGET}}/{{.PROFILE}}/slim"
data-plane:run:server:
desc: "Run the server"
cmds:
- task: data-plane:build
- task: data-plane:run
vars:
ARGS: ""
BIN: "slim"
BIN_ARGS: "--config ./config/base/server-config.yaml"
data-plane:run:server-with-otel:
desc: "Run the server with OpenTelemetry enabled"
cmds:
- task: data-plane:build
- task: data-plane:run
vars:
ARGS: ""
BIN: "slim"
BIN_ARGS: "--config ./config/telemetry/server-config.yaml"
data-plane:slimctl:run:
desc: "Run the Rust slimctl binary"
cmds:
- task: data-plane:run
vars:
BIN: "slimctl"
ARGS: "--package agntcy-slimctl"
BIN_ARGS: "{{.BIN_ARGS}}"
vars:
BIN_ARGS: '{{.BIN_ARGS | default "--help"}}'
data-plane:slimctl:build:
desc: "Build Rust slimctl and stage it in .dist/bin"
cmds:
- cargo build --package agntcy-slimctl
- mkdir -p ../.dist/bin
- cp target/debug/slimctl ../.dist/bin/slimctl
data-plane:telemetry:start:
desc: "Start telemetry stack"
cmds:
- docker compose -f ./config/telemetry/docker-compose.yml up
data-plane:python:packaging:
desc: "Generate python packages"
dir: ./python
cmds:
- task python:bindings:packaging PROFILE={{.PROFILE}} TARGET={{.TARGET}}
vars:
PROFILE: '{{.PROFILE | default "debug"}}'
TARGET: '{{.TARGET | default ""}}'
data-plane:bindings:test:
desc: "Test the Python bindings"
dir: ./bindings/python
cmds:
- task python:bindings:test TESTS={{.TESTS}}
vars:
TESTS: '{{.TESTS | default ""}}'
data-plane:core:test:
desc: "Run core end to end tests"
dir: ./testing
cmds:
- |
task test:group-session
task test:point-to-point-session
data-plane:slim:version:
desc: "Get version from corresponding git tag"
cmds:
- git describe --tags --match "slim-v*" | cut -d 'v' -f 2
data-plane:generate:grpc-json-schema:
desc: "Generate the gRPC schema"
cmds:
- cargo run --bin generate-schema
# Enhanced coverage task that includes Python bindings coverage
data-plane:coverage-full:
desc: "Run full tests coverage including Python bindings"
cmds:
- task: data-plane:test:coverage
vars:
ARGS: "{{.GLOBAL_ARGS}} --all-targets --locked --all-features"
- task: data-plane:core:test