File tree Expand file tree Collapse file tree 1 file changed +8
-8
lines changed
Expand file tree Collapse file tree 1 file changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -14,15 +14,15 @@ export async function createEnvFile() {
1414 // Read the config file
1515 const config = JSON . parse ( fs . readFileSync ( configPath , 'utf8' ) ) ;
1616
17- // Create .env content
17+ // Create .env content with correct property mappings
1818 const envContent = [
19- `MONGODB_URI="${ config . mongodbUri } "` ,
20- `EMBEDDING_PROVIDER="${ config . embeddingProvider } "` ,
21- `EMBEDDING_API_KEY="${ config . embeddingApiKey } "` ,
22- `EMBEDDING_MODEL="${ config . embeddingModel } "` ,
23- `VECTOR_INDEX="${ config . vectorSearchIndex } "` ,
24- `MONGODB_DATABASE_NAME="${ config . databaseName } "` ,
25- `MONGODB_COLLECTION_NAME="${ config . collectionName } "` ,
19+ `MONGODB_URI="${ config . mongoUrl } "` ,
20+ `EMBEDDING_PROVIDER="${ config . embedding ?. provider || config . provider } "` ,
21+ `EMBEDDING_API_KEY="${ config . apiKey } "` ,
22+ `EMBEDDING_MODEL="${ config . embedding ?. model || config . model } "` ,
23+ `VECTOR_INDEX="${ config . indexName } "` ,
24+ `MONGODB_DATABASE_NAME="${ config . database } "` ,
25+ `MONGODB_COLLECTION_NAME="${ config . collection } "` ,
2626 ] . join ( '\n' ) ;
2727
2828 // Write to .env file
You can’t perform that action at this time.
0 commit comments