diff --git a/meilisearch-http/src/option.rs b/meilisearch-http/src/option.rs index 0f1ff5970..60842709e 100644 --- a/meilisearch-http/src/option.rs +++ b/meilisearch-http/src/option.rs @@ -146,7 +146,7 @@ pub struct Opt { pub log_level: String, #[serde(skip)] - #[clap(skip)] + #[clap(flatten)] pub indexer_options: IndexerOpts, #[serde(flatten)] diff --git a/meilisearch-lib/src/options.rs b/meilisearch-lib/src/options.rs index 195576799..14080fd19 100644 --- a/meilisearch-lib/src/options.rs +++ b/meilisearch-lib/src/options.rs @@ -25,7 +25,7 @@ pub struct IndexerOpts { /// In case the engine is unable to retrieve the available memory the engine will /// try to use the memory it needs but without real limit, this can lead to /// Out-Of-Memory issues and it is recommended to specify the amount of memory to use. - #[clap(long, default_value_t)] + #[clap(long, default_value_t, env = "MEILI_MAX_MEMORY")] pub max_memory: MaxMemory, /// The name of the compression algorithm to use when compressing intermediate @@ -40,7 +40,7 @@ pub struct IndexerOpts { pub chunk_compression_level: Option, /// Number of parallel jobs for indexing, defaults to # of CPUs. - #[clap(long)] + #[clap(long, env = "MEILI_INDEXING_JOBS")] pub indexing_jobs: Option, }