Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add/update CosmosDB examples for native Azure #923

Merged
merged 5 commits into from
Mar 1, 2021

Conversation

lblackstone
Copy link
Member

No description provided.

// Create an Azure resource (Storage Account)
var storageAccount = new Storage.StorageAccount("storageAccount", new Storage.StorageAccountArgs
{
AccountName = "logicappdemosa21",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit - with 0.7.0 (autonaming) we should just let the provider handle the names here.

2. Set the required configuration variables for this program, and log into Azure:

```bash
$ pulumi config set azure:location westeurope
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

s/azure/azure-nextgen (or azure-native)

# Create an Azure resource (Storage Account)
storage_account = storage.StorageAccount(
"storageAccount",
account_name="logicappdemosa21",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

rely on autonaming here with 0.7.0.

@@ -0,0 +1,3 @@
pulumi>=2.0.0,<3.0.0
pulumi-azure-nextgen>=0.6.1
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Switch to 0.7.0 (everywhere)

accountName: accountName,
const accountKeys = pulumi
.all([cosmosdbAccount.name, resourceGroup.name])
.apply(([cosmosdbAccountName, resourceGroupName]) => documentdb.listDatabaseAccountKeys({
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! I was trying to find a neat way to unfold the list but punted :)

2. Set the required configuration variables for this program, and log into Azure:

```bash
$ pulumi config set azure:location westeurope
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
$ pulumi config set azure:location westeurope
$ pulumi config set azure-nextgen:location westeurope

@viveklak
Copy link
Contributor

Looks good overall. We can either merge with the existing azure-nextgen dependency (probably still want to fix the readme's config entries for setting location) and follow-up with a conversion to azure-native or do all of that now. Whatever you prefer @lblackstone

@lblackstone
Copy link
Member Author

Looks good overall. We can either merge with the existing azure-nextgen dependency (probably still want to fix the readme's config entries for setting location) and follow-up with a conversion to azure-native or do all of that now. Whatever you prefer @lblackstone

I'll update to 0.7.0 on this PR.

@mikhailshilkov
Copy link
Member

I'll merge this and open an azure-native PR for all examples

@mikhailshilkov mikhailshilkov merged commit d2a9ee3 into master Mar 1, 2021
@pulumi-bot pulumi-bot deleted the lblackstone/native-azure-cosmos branch March 1, 2021 08:01
dixler pushed a commit that referenced this pull request Jan 21, 2022
* Add/update CosmosDB examples for native Azure

* Python

* C# WIP

* Fixed C#

* One more fix
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants