-
Notifications
You must be signed in to change notification settings - Fork 41
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
35 changed files
with
150 additions
and
320 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,46 +1,24 @@ | ||
import * as pulumi from "@pulumi/pulumi"; | ||
import * as azurerm from "../../sdk/nodejs"; | ||
import * as random from "@pulumi/random"; | ||
import * as resources from "@pulumi/azurerm/resources/latest"; | ||
import * as cosmosdb from "./component"; | ||
|
||
const resourceGroup = new azurerm.resources.latest.ResourceGroup("rg", { | ||
resourceGroupName: "azurerm-cosmos", | ||
const randomString = new random.RandomString("random", { | ||
length: 12, | ||
special: false, | ||
upper: false, | ||
}); | ||
|
||
const resourceGroup = new resources.ResourceGroup("rg", { | ||
resourceGroupName: randomString.result, | ||
location: "westeurope", | ||
tags: { | ||
Owner: "mikhailshilkov", | ||
}, | ||
}); | ||
|
||
export const cosmosdbAccount = new cosmosdb.DatabaseAccount("pulumicosmosdb", { | ||
export const cosmosdbAccount = new cosmosdb.DatabaseAccount(randomString.result, { | ||
resourceGroup, | ||
api: "Sql", | ||
consisencyPolicy: { defaultConsistencyLevel: "Session" }, | ||
location: { | ||
type: "multiple", | ||
regions: ["westeurope", "northeurope"], | ||
enableMultipleWriteLocations: true, | ||
enableAutomaticFailover: true, | ||
type: "single", | ||
region: "westeurope", | ||
}, | ||
}); | ||
|
||
// const cosmosdbAccount2 = new azurerm.documentdb.latest.DatabaseAccount("pulumicosmosdb", { | ||
// resourceGroupName: resourceGroup.name, | ||
// accountName: "pulumicosmosdb", | ||
// location: resourceGroup.location, | ||
// kind: "GlobalDocumentDB", | ||
// consistencyPolicy: { | ||
// defaultConsistencyLevel: "Session", | ||
// }, | ||
// locations: [{ | ||
// locationName: "westeurope", | ||
// failoverPriority: 0, | ||
// isZoneRedundant: false | ||
// }, { | ||
// locationName: "northeurope", | ||
// failoverPriority: 1, | ||
// isZoneRedundant: false | ||
// }], | ||
// databaseAccountOfferType: "Standard", | ||
// enableAutomaticFailover: true, | ||
// capabilities: [], | ||
// enableMultipleWriteLocations: true, | ||
// }); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
33 changes: 20 additions & 13 deletions
33
examples/azure-ts-hdinsight-spark/index.ts → examples/hdinsight-spark/index.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
Oops, something went wrong.