Files
muscl/Cargo.toml
h7x4 9b279a4956
All checks were successful
Build and test / check-license (push) Successful in 1m7s
Build and test / check (push) Successful in 1m47s
Build and test / build (push) Successful in 2m48s
Build and test / test (push) Successful in 3m48s
Build and test / docs (push) Successful in 6m46s
flake.lock: bump, Cargo.{toml,lock}: update inputs
2026-04-02 14:00:30 +09:00

189 lines
5.0 KiB
TOML

[package]
name = "muscl"
version = "1.0.0"
edition = "2024"
resolver = "2"
license = "BSD-3-Clause"
authors = [
"Programvareverkstedet <projects@pvv.ntnu.no>",
]
homepage = "https://git.pvv.ntnu.no/Projects/muscl"
repository = "https://git.pvv.ntnu.no/Projects/muscl"
documentation = "https://pages.pvv.ntnu.no/Projects/muscl/main/docs/muscl"
description = "A command-line utility for MySQL administration for non-admin users"
categories = ["command-line-interface", "command-line-utilities"]
keywords = ["mysql", "cli", "administration"]
readme = "README.md"
autobins = false
autolib = false
[dependencies]
anyhow = "1.0.102"
async-bincode = "0.8.0"
bincode = "2.0.1"
clap = { version = "4.6.0", features = ["cargo", "derive"] }
clap-verbosity-flag = { version = "3.0.4", features = [ "tracing" ] }
clap_complete = { version = "4.6.0", features = ["unstable-dynamic"] }
color-print = "0.3.7"
const_format = "0.2.35"
derive_more = { version = "2.1.1", features = ["display", "error"] }
dialoguer = "0.12.0"
futures-util = "0.3.32"
humansize = "2.1.3"
indoc = "2.0.7"
itertools = "0.14.0"
nix = { version = "0.31.2", features = ["fs", "process", "socket", "user"] }
num_cpus = "1.17.0"
prettytable = "0.10.0"
rand = "0.10.0"
serde = "1.0.228"
serde_json = { version = "1.0.149", features = ["preserve_order"] }
sqlx = { version = "0.8.6", features = ["runtime-tokio", "mysql", "tls-rustls"] }
thiserror = "2.0.18"
tokio = { version = "1.50.0", features = ["rt-multi-thread", "macros", "signal"] }
tokio-serde = { version = "0.9.0", features = ["bincode"] }
tokio-stream = "0.1.18"
tokio-util = { version = "0.7.18", features = ["codec", "rt"] }
toml = "1.1.2"
tracing = { version = "0.1.44", features = ["log"] }
tracing-subscriber = "0.3.23"
uuid = { version = "1.23.0", features = ["v4"] }
[target.'cfg(target_os = "linux")'.dependencies]
landlock = "0.4.4"
sd-notify = "0.5.0"
tracing-journald = "0.3.2"
[build-dependencies]
anyhow = "1.0.102"
build-info-build = "0.0.43"
git2 = { version = "0.20.4", default-features = false }
[dev-dependencies]
pretty_assertions = "1.4.1"
regex = "1.12.3"
[features]
default = ["mysql-admutils-compatibility"]
mysql-admutils-compatibility = []
suid-sgid-mode = []
[lib]
name = "muscl_lib"
path = "src/lib.rs"
[[bin]]
name = "muscl"
bench = false
path = "src/bin/muscl.rs"
[[bin]]
name = "muscl-server"
bench = false
path = "src/bin/muscl_server.rs"
[profile.release-lto]
inherits = "release"
strip = true
lto = true
codegen-units = 1
[package.metadata.deb]
name = "muscl"
priority = "optional"
section = "databases"
depends = "$auto"
license-file = ["LICENSE", "0"]
maintainer = "Programvareverkstedet <projects@pvv.ntnu.no>"
copyright = "Copyright (c) 2025, Programvareverkstedet"
# NOTE: try to keep this in sync with README, and keep an 80 char limit.
extended-description = """
Muscl is a CLI tool that let's unprivileged users perform administrative
operations on a MySQL DBMS, given the are authorized to perform the action
on the database or database user in question. The default authorization
mechanism is to only let the user perform these actions on databases and
database users that are prefixed with their username, or with the name of any
unix group that the user is a part of. i.e. `<user>_mydb`, `<user>_mydbuser`,
or `<group>_myotherdb`.
The available administrative actions include:
- creating/listing/modifying/deleting databases and database users
- modifying privileges for a database user on a database
- changing the passwords of the database users
- locking and unlocking database users
- ... more to come
The software is designed to be run as a client and a server. The server has
administrative access to the mysql server, and is responsible for authorizing
any requests from the clients.
This software is designed for multi-user servers, like tilde servers,
university servers, etc.\
"""
changelog = "CHANGELOG.md"
assets = [
[
"target/release/muscl",
"usr/bin/",
"755",
],
[
"target/release/muscl-server",
"usr/bin/",
"755",
],
[
"target/release/mysql-useradm",
"usr/bin/",
"755",
],
[
"target/release/mysql-dbadm",
"usr/bin/",
"755",
],
[
"assets/debian/config.toml",
"etc/muscl/config.toml",
"644",
],
[
"assets/debian/group_denylist.txt",
"etc/muscl/group_denylist.txt",
"644",
],
[
"assets/completions/_*",
"usr/share/zsh/site-functions/completions/",
"644",
],
[
"assets/completions/*.bash",
"usr/share/bash-completion/completions/",
"644",
],
[
"assets/completions/*.fish",
"usr/share/fish/vendor_completions.d/",
"644",
],
[
"README.md",
"usr/share/doc/muscl/",
"644",
],
[
"docs/*.md",
"usr/share/doc/muscl/docs/",
"644",
],
]
preserve-symlinks = true
maintainer-scripts = "debian/"
systemd-units = [
{ unit-name = "muscl", unit-scripts = "assets/systemd", enable = true },
]