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
7 changes: 6 additions & 1 deletion .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -190,6 +190,10 @@ jobs:
id: deploy
run: |
set -e

# Generate current timestamp in desired format: YYYY-MM-DDTHH:MM:SS.SSSSSSSZ
current_date=$(date -u +"%Y-%m-%dT%H:%M:%S.%7NZ")

az deployment group create \
--name ${{ env.SOLUTION_PREFIX }}-deployment \
--resource-group ${{ env.RESOURCE_GROUP_NAME }} \
Expand All @@ -210,7 +214,8 @@ jobs:
enableTelemetry=true \
enableRedundancy=false \
enableScalability=false \
createdBy="Pipeline"
createdBy="Pipeline" \
tags="{'SecurityControl':'Ignore','Purpose':'Deploying and Cleaning Up Resources for Validation','CreatedDate':'$current_date'}"

- name: Get Deployment Output and extract Values
id: get_output
Expand Down
3 changes: 2 additions & 1 deletion infra/main.bicep
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ param enableScalability bool = false
param aiDeploymentsLocation string

@description('Optional created by user name')
param createdBy string = empty(deployer().userPrincipalName) ? '' : split(deployer().userPrincipalName, '@')[0]
param createdBy string = contains(deployer(), 'userPrincipalName')? split(deployer().userPrincipalName, '@')[0]: deployer().objectId

// ========== Resource Group Tag ========== //
resource resourceGroupTags 'Microsoft.Resources/tags@2021-04-01' = {
Expand All @@ -113,6 +113,7 @@ resource resourceGroupTags 'Microsoft.Resources/tags@2021-04-01' = {
tags: {
...tags
TemplateName: 'DKM'
Type: enablePrivateNetworking ? 'WAF' : 'Non-WAF'
CreatedBy: createdBy
}
}
Expand Down