pub struct ConfigInitArgs {
pub output: Option<PathBuf>,
pub force: bool,
pub chain: Option<String>,
pub origin: Option<String>,
pub client: bool,
}Expand description
Write a default TOML configuration file.
Fields§
§output: Option<PathBuf>Path to write the config file [default: ~/.decdn/node.toml].
force: boolOverwrite existing config file if present.
chain: Option<String>Deployment to bake in: chain id + contract addresses are filled from the
shipped deployment manifest so the config runs out of the box. Omit to
select the only known network; pass none for a blank template with
every address left to fill in.
origin: Option<String>Configure an ORIGIN node: write an active [cache.origin] pull-through
backend. Accepts an http(s):// base URL (http origin), a file:///
path (fs origin), or s3 / s3://<bucket> (S3-compatible origin —
bare s3 leaves a placeholder bucket to edit; either form leaves
region/endpoint/prefix for the generated comments to walk through).
Presence of an origin backend is the role signal —
cache.relay_foreign_namespaces then derives to false (origin-only).
Omit for a relay node (no origin; serves foreign content for pay;
derives to true).
client: boolWrite a fetch-only CLIENT config: identity + chain coordinates for a
consumer that fetches and pays (decdn get), with none of the
cache/origin/serving sections a decdn-node daemon reads.
Trait Implementations§
Source§impl Args for ConfigInitArgs
impl Args for ConfigInitArgs
Source§fn augment_args<'b>(__clap_app: Command) -> Command
fn augment_args<'b>(__clap_app: Command) -> Command
Source§fn augment_args_for_update<'b>(__clap_app: Command) -> Command
fn augment_args_for_update<'b>(__clap_app: Command) -> Command
Command so it can instantiate self via
FromArgMatches::update_from_arg_matches_mut Read moreSource§impl Debug for ConfigInitArgs
impl Debug for ConfigInitArgs
Source§impl FromArgMatches for ConfigInitArgs
impl FromArgMatches for ConfigInitArgs
Source§fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
Source§fn from_arg_matches_mut(
__clap_arg_matches: &mut ArgMatches,
) -> Result<Self, Error>
fn from_arg_matches_mut( __clap_arg_matches: &mut ArgMatches, ) -> Result<Self, Error>
Source§fn update_from_arg_matches(
&mut self,
__clap_arg_matches: &ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches( &mut self, __clap_arg_matches: &ArgMatches, ) -> Result<(), Error>
ArgMatches to self.Source§fn update_from_arg_matches_mut(
&mut self,
__clap_arg_matches: &mut ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches_mut( &mut self, __clap_arg_matches: &mut ArgMatches, ) -> Result<(), Error>
ArgMatches to self.Auto Trait Implementations§
impl Freeze for ConfigInitArgs
impl RefUnwindSafe for ConfigInitArgs
impl Send for ConfigInitArgs
impl Sync for ConfigInitArgs
impl Unpin for ConfigInitArgs
impl UnsafeUnpin for ConfigInitArgs
impl UnwindSafe for ConfigInitArgs
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more