Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ Options:
validate the certificate presented by the mongod/mongos instance
--tlsCertificateKeyFile <path> Specifies the location of a local .pem file that contains either the
client's TLS/SSL certificate and key
--tlsCertificateKeyFilePassword <password> Specifies the password to de-crypt the tlsCertificateKeyFile
-m --db-map [dump-db-name=target-db-name...] Map the databases in the dump with the target databases. We have our own naming convention for the production databases, but it is up to the customers to name their databases (default: ["google_production=codefresh","chart-manager=charts-manager","kubernetes-monitor=k8s-monitor"])
-h, --help display help for command
```
Expand Down Expand Up @@ -108,6 +109,7 @@ Options:
validate the certificate presented by the mongod/mongos instance
--tlsCertificateKeyFile <path> Specifies the location of a local .pem file that contains either the
client's TLS/SSL certificate and key
--tlsCertificateKeyFilePassword <password> Specifies the password to de-crypt the tlsCertificateKeyFile
-h, --help display help for command
```

Expand Down Expand Up @@ -140,6 +142,7 @@ Options:
validate the certificate presented by the mongod/mongos instance
--tlsCertificateKeyFile <path> Specifies the location of a local .pem file that contains either the
client's TLS/SSL certificate and key
--tlsCertificateKeyFilePassword <password> Specifies the password to de-crypt the tlsCertificateKeyFile
-f --force Create indexes even on heavily populated collections, which may take a while
-m --db-map [dump-db-name=target-db-name...] Map the databases in the dump with the target databases. We have our own naming convention for the production databases, but it is up to the customers to name their databases (default: ["google_production=codefresh","chart-manager=charts-manager","kubernetes-monitor=k8s-monitor"])
-h, --help display help for command
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "index-alignment",
"version": "0.1.0",
"version": "0.2.0",
"main": "dist/index.js",
"private": true,
"type": "module",
Expand Down
1 change: 1 addition & 0 deletions src/get-mongo-client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ export const getMongoClient = (options: Partial<MongoClientOptions> & { uri: str
tlsInsecure: options.tlsInsecure,
tlsCAFile: options.tlsCAFile,
tlsCertificateKeyFile: options.tlsCertificateKeyFile,
tlsCertificateKeyFilePassword: options.tlsCertificateKeyFilePassword,
} satisfies MongoClientOptions;
logger.stderr(`The following options will be used for the MongoDB connection: ${JSON.stringify(clientOptions, null, 2)}`);
return new MongoClient(options.uri, clientOptions);
Expand Down
16 changes: 16 additions & 0 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@ program
'--tlsCertificateKeyFile <path>',
`Specifies the location of a local .pem file that contains either the client's TLS/SSL certificate and key`,
)
.option(
'--tlsCertificateKeyFilePassword <password>',
'Specifies the password to de-crypt the tlsCertificateKeyFile',
)
.action(dumpAllIndexes);

program
Expand All @@ -52,6 +56,10 @@ program
'--tlsCertificateKeyFile <path>',
`Specifies the location of a local .pem file that contains either the client's TLS/SSL certificate and key`,
)
.option(
'--tlsCertificateKeyFilePassword <password>',
'Specifies the password to de-crypt the tlsCertificateKeyFile',
)
.action(stats);

program
Expand All @@ -77,6 +85,10 @@ program
'--tlsCertificateKeyFile <path>',
`Specifies the location of a local .pem file that contains either the client's TLS/SSL certificate and key`,
)
.option(
'--tlsCertificateKeyFilePassword <password>',
'Specifies the password to de-crypt the tlsCertificateKeyFile',
)
.option(
'-m --db-map [dump-db-name=target-db-name...]',
'Map the databases in the dump with the target databases. We have our own naming convention for the production databases, but it is up to the customers to name their databases',
Expand Down Expand Up @@ -107,6 +119,10 @@ program
'--tlsCertificateKeyFile <path>',
`Specifies the location of a local .pem file that contains either the client's TLS/SSL certificate and key`,
)
.option(
'--tlsCertificateKeyFilePassword <password>',
'Specifies the password to de-crypt the tlsCertificateKeyFile',
)
.option('-f --force', 'Create indexes even on heavily populated collections, which may take a while')
.option(
'-m --db-map [dump-db-name=target-db-name...]',
Expand Down