mirror of
https://github.com/cloudflare/pingora.git
synced 2024-09-20 02:31:35 +02:00
Addressing github #231 - Cleaning up cli-help text
This commit is contained in:
parent
5cf12e17c2
commit
9ea87b231e
2 changed files with 19 additions and 13 deletions
2
.bleep
2
.bleep
|
@ -1 +1 @@
|
||||||
755ce66cddc4805c0a264c31a2e3cd7cab352755
|
719b4dcafd471ecfa9e4ade3abfb217929afddc6
|
|
@ -122,35 +122,41 @@ impl Default for ServerConf {
|
||||||
#[clap(name = "basic")]
|
#[clap(name = "basic")]
|
||||||
pub struct Opt {
|
pub struct Opt {
|
||||||
/// Whether this server should try to upgrade from a running old server
|
/// Whether this server should try to upgrade from a running old server
|
||||||
///
|
#[clap(
|
||||||
/// `-u` or `--upgrade` can be used
|
short,
|
||||||
#[clap(short, long)]
|
long,
|
||||||
|
help = "This is the base set of command line arguments for a pingora-based service"
|
||||||
|
)]
|
||||||
pub upgrade: bool,
|
pub upgrade: bool,
|
||||||
|
|
||||||
/// Whether should run this server in the background
|
/// Whether should run this server in the background
|
||||||
///
|
|
||||||
/// `-d` or `--daemon` can be used
|
|
||||||
#[clap(short, long)]
|
#[clap(short, long)]
|
||||||
pub daemon: bool,
|
pub daemon: bool,
|
||||||
|
|
||||||
/// Not actually used. This flag is there so that the server is not upset seeing this flag
|
/// Not actually used. This flag is there so that the server is not upset seeing this flag
|
||||||
/// passed from `cargo test` sometimes
|
/// passed from `cargo test` sometimes
|
||||||
#[clap(long)]
|
#[clap(long, hidden = true)]
|
||||||
pub nocapture: bool,
|
pub nocapture: bool,
|
||||||
|
|
||||||
/// Test the configuration and exit
|
/// Test the configuration and exit
|
||||||
///
|
///
|
||||||
/// When this flag is set, calling `server.bootstrap()` will exit the process without errors
|
/// When this flag is set, calling `server.bootstrap()` will exit the process without errors
|
||||||
///
|
///
|
||||||
/// This flag is useful for upgrading service where the user wants to make sure the new
|
/// This flag is useful for upgrading service where the user wants to make sure the new
|
||||||
/// service can start before shutting down the old server process.
|
/// service can start before shutting down the old server process.
|
||||||
///
|
#[clap(
|
||||||
/// `-t` or `--test` can be used
|
short,
|
||||||
#[clap(short, long)]
|
long,
|
||||||
|
help = "This flag is useful for upgrading service where the user wants \
|
||||||
|
to make sure the new service can start before shutting down \
|
||||||
|
the old server process."
|
||||||
|
)]
|
||||||
pub test: bool,
|
pub test: bool,
|
||||||
|
|
||||||
/// The path to the configuration file.
|
/// The path to the configuration file.
|
||||||
///
|
///
|
||||||
/// See [`ServerConf`] for more details of the configuration file.
|
/// See [`ServerConf`] for more details of the configuration file.
|
||||||
///
|
#[clap(short, long, help = "The path to the configuration file.")]
|
||||||
/// `-c` or `--conf` can be used
|
|
||||||
#[clap(short, long)]
|
|
||||||
pub conf: Option<String>,
|
pub conf: Option<String>,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue