Skip to content
This repository has been archived by the owner on Jul 26, 2024. It is now read-only.

Commit

Permalink
Merge pull request #18 from barrucadu/name-env
Browse files Browse the repository at this point in the history
Alow setting `--name` via env vars
  • Loading branch information
barrucadu authored Mar 17, 2024
2 parents b18e4b8 + 4020034 commit 13e4394
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion crates/apid/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ pub static SPECIAL_HOSTNAME: &str = "api";
struct Args {
/// Name of this instance, must be unique across the cluster. If
/// unspecified, a random name is generated.
#[clap(long)]
#[clap(long, env = "NODE_NAME")]
pub name: Option<String>,

/// Cluster address to bind on to provide services to pods. This, or
Expand Down
2 changes: 1 addition & 1 deletion crates/reaperd/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ use reaperd::watcher;
struct Args {
/// Name of this instance, must be unique across the cluster. If
/// unspecified, a random name is generated.
#[clap(long)]
#[clap(long, env = "NODE_NAME")]
pub name: Option<String>,

#[command(flatten)]
Expand Down
2 changes: 1 addition & 1 deletion crates/schedulerd/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ use schedulerd::watcher;
struct Args {
/// Name of this instance, must be unique across the cluster. If
/// unspecified, a random name is generated.
#[clap(long)]
#[clap(long, env = "NODE_NAME")]
pub name: Option<String>,

#[command(flatten)]
Expand Down
2 changes: 1 addition & 1 deletion crates/workerd/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ pub static SPECIAL_HOSTNAME: &str = "dns";
struct Args {
/// Name of this instance, must be unique across the cluster. If
/// unspecified, a random name is generated.
#[clap(long)]
#[clap(long, env = "NODE_NAME")]
pub name: Option<String>,

/// Address to bind on to provide services to local pods. Must be reachable
Expand Down

0 comments on commit 13e4394

Please sign in to comment.