-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmise.toml
More file actions
37 lines (33 loc) · 1.1 KB
/
mise.toml
File metadata and controls
37 lines (33 loc) · 1.1 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
[tools]
cargo-binstall = "1.17.6"
"cargo:cargo-zigbuild" = "0.22.1"
rust = "1.93.1"
watchexec = "2.5.0"
yq = "4.52.4"
zig = "master"
[tasks.build]
dir = "{{ config_root }}"
outputs = ["target/debug/wgexporter"]
sources = ["Cargo.toml", "Cargo.lock", "src/**/*.rs"]
run = "cargo build"
[tasks.'docker:build']
dir = "{{ config_root }}"
sources = ["Dockerfile", "docker/*", "Cargo.toml", "Cargo.lock", "src/**/*.rs"]
usage = """
flag "--repository <repository>" help="oci repository" default="ghcr.io/tehlordvortex"
flag "--push" default="false"
flag "--tag <tag>" default="dev"
"""
run = """
docker buildx build --platform=linux/amd64,linux/arm64 --push={{ usage.push }} \
-t {{ usage.repository }}/wgexporter:{{ usage.tag }} .
"""
[tasks.'docker:build:versioned']
run = "mise docker:build --tag v$(yq '.package.version' Cargo.toml)"
[tasks.vmetrics]
dir = "{{ config_root }}"
run = """
docker run --rm -it --add-host=host.docker.internal:host-gateway \
--volume ./dev:/config:ro -p 8428:8428 victoriametrics/victoria-metrics:v1.136.0 \
-enableTCP6 -selfScrapeInterval=1s -promscrape.config=/config/prometheus.yaml
"""