Azure / Azure/bicep

Should "adminusername-should-not-be-literal" also apply to indirectly through a variable?

Open
#5,102 2 comments 0 reactions 0 assignees View on GitHub
devdiv story: linter rules
Dominant language
Bicep
Stars
3.6k
Forks
830
Avg merge
1d 21m
Merged PRs (30d)
79

Description

Uche:
> It's not clear that a variable is bad for adminUserName, "instead use a parameter"

Current behavior is that this fails the test:
```bicep
var adminUsername = 'hello'

resource vm 'Microsoft.Compute/virtualMachines@2020-12-01' = {
name: 'name'
location: resourceGroup().location
properties: {
osProfile: {
adminUsername: adminUsername
}
}
}
```

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the shown Bicep snippet and locating the implementation and tests for the "adminusername-should-not-be-literal" rule. Confirm whether indirect values through variables should be accepted or rejected; done means the rule and its test coverage reflect that decision.

Written by the indexing model from the issue text.

Assessment

Domain
tooling
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.