-
Notifications
You must be signed in to change notification settings - Fork 13
/
Copy pathCargo.toml
69 lines (61 loc) · 2.28 KB
/
Cargo.toml
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
[package]
name = "logram"
version = "2.0.0"
authors = ["Max Eliseev <seevmx@gmail.com>"]
description = "Utility that takes logs from anywhere and sends them to Telegram"
license = "MIT"
readme = "README.md"
edition = "2018"
[features]
bin_core = ["clap", "serde_yaml", "teloxide", "tokio", "chrono", "futures", "hostname", "cfg-if"]
ls_counter = []
ls_filesystem = ["notify"]
ls_journald = ["systemd"]
ls_docker = ["bollard"]
[[bin]]
name = "logram"
doc = false
doctest = false
required-features = ["bin_core"]
[lib]
name = "logram"
path = "src/lib/mod.rs"
[dependencies]
anyhow = "1.0"
serde = { version = "1.0", features = ["derive"] }
reqwest = { version = "0.10", features = ["blocking", "json", "socks"] }
# bin
clap = { version = "2.33", optional = true }
serde_yaml = { version = "0.8", optional = true }
teloxide = { version = "0.3", optional = true }
tokio = { version = "0.2", features = ["rt-threaded", "macros", "time", "blocking"], optional = true }
chrono = { version = "0.4", optional = true }
futures = { version = "0.3", optional = true }
hostname = { version = "0.3", optional = true }
cfg-if = { version = "1.0", optional = true }
notify = { version = "4.0", optional = true }
systemd = { version = "0.7", optional = true }
bollard = { version = "0.9", optional = true }
# lib
log = { version = "0.4", features = ["std"] }
serde_json = { version = "1.0" }
[package.metadata.deb]
maintainer-scripts = "assets/scripts/"
systemd-units = { enable = false, start = false }
depends = "$auto"
section = "utility"
conf-files = ["/etc/logram.yaml"]
features = ["bin_core", "ls_counter", "ls_filesystem", "ls_journald", "ls_docker"]
assets = [
["target/release/logram", "usr/bin/", "755"],
["README.md", "usr/share/doc/logram/README", "644"],
["assets/config.yaml", "etc/logram.yaml", "644"]
]
[package.metadata.generate-rpm]
assets = [
{ source = "target/release/logram", dest = "/usr/bin/logram", mode = "0755" },
{ source = "assets/config.yaml", dest = "/etc/logram.yaml", config = true, mode = "0644" },
{ source = "assets/scripts/logram.service", dest = "/lib/systemd/system/logram.service", mode = "0644" },
{ source = "LICENSE", dest = "/usr/share/doc/logram/LICENSE", doc = true, mode = "0644" },
{ source = "README.md", dest = "/usr/share/doc/logram/README.md", doc = true, mode = "0644" }
]