You can use a search index configuration file to specify the settings required when you create an Atlas Search index or update an Atlas Search index using the Atlas CLI. The Atlas CLI accepts .json
search index configuration files.
Available Settings
When you create an Atlas Search index using a configuration file, you can specify any settings that are listed in Create One Atlas Search Index under Request Body Schema.
When you update an Atlas Search index using a configuration file, you can specify any settings that are listed in Update One Atlas Search Index under Request Body Schema.
Create a Configuration File
Crear un índice de Atlas Search
Follow these steps to create an Atlas Search index with a configuration file:
Copy the sample request for Create One Atlas Search Index.
Navigate to the Create One Atlas Search Index section of the Atlas Admin API specification.
Under Request samples on the right side, click Expand all.
Haz clic en Copy para copiar la solicitud de ejemplo.
Run the atlas clusters search indexes create command with the --file option.
Specify the path to the file you saved with the --file flag.
Update an Atlas Search Index
Follow these steps to update an Atlas Search index with a configuration file:
Copy the sample request for Update One Atlas Search Index.
Navigate to the Update One Atlas Search Index section of the Atlas Admin API specification.
Under Request samples on the right side, click Expand all.
Haz clic en Copy para copiar la solicitud de ejemplo.
Ejecuta el comando atlas clústeres índices de búsqueda actualizar con la opción --file.
Specify the path to the file you saved with the --file flag.