Skip to content

feat(gallery): add linux-vm-cosmosdb scenario#109

Draft
petender wants to merge 1 commit into
MicrosoftLearning:mainfrom
petender:contribute/linux-vm-cosmosdb
Draft

feat(gallery): add linux-vm-cosmosdb scenario#109
petender wants to merge 1 commit into
MicrosoftLearning:mainfrom
petender:contribute/linux-vm-cosmosdb

Conversation

@petender

Copy link
Copy Markdown
Collaborator

New Template Registration

Field Value
Scenario linux-vm-cosmosdb
Repo petender/tdd-azd-linux-vm-cosmosdb
Tags az-104,msft,virtualmachine,cosmosdb,vnets,loganalytics,dotnet
Sample App Yes
Demo Guide Yes
Contributor @petender

Tag Validation

All tags validated against src/data/tags.tsx TagType union: ✅ PASSED

Deployment

gh repo clone petender/tdd-azd-linux-vm-cosmosdb cd tdd-azd-linux-vm-cosmosdb azd init azd up

@rob-foulkrod

Copy link
Copy Markdown
Collaborator

While validating this template, I found that deployment requires an SSH public key, but that requirement is not surfaced in the README or through an interactive azd up prompt.

The template reads the key from an environment variable:

param sshPublicKey = readEnvironmentVariable('AZURE_VM_SSH_PUBLIC_KEY', '')

I tested with a clean .azure environment and no AZURE_VM_SSH_PUBLIC_KEY set. azd up did not prompt for the SSH key; it proceeded into deployment and eventually failed during VM validation:

InvalidParameter: The value of parameter linuxConfiguration.ssh.publicKeys.keyData is invalid.

Cleanup with azd down --force completed successfully.

To improve the trainer experience, could you either:

  1. Wire this as a prompted AZD input so azd up asks for the SSH public key, or
  2. Update the README deployment steps to explicitly instruct users to set the value before running azd up, for example:
azd env set AZURE_VM_SSH_PUBLIC_KEY "<contents of your public key>" -e <envName>

The current hidden environment-variable requirement makes the template hard to deploy successfully from the documented instructions.

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.

2 participants