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

Make ContainerInsights DataCollectionRuleName consistent with Portal and other onboarding clients #211

Merged
merged 3 commits into from
Feb 2, 2023
Merged
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
Original file line number Diff line number Diff line change
Expand Up @@ -624,7 +624,9 @@ def _ensure_container_insights_dcr_for_monitoring(cmd, subscription_id, cluster_
except HttpResponseError as ex:
raise ex

dataCollectionRuleName = f"MSCI-{cluster_name}-{cluster_region}"
dataCollectionRuleName = f"MSCI-{workspace_region}-{cluster_name}"
# Max length of the DCR name is 64 chars
dataCollectionRuleName = dataCollectionRuleName[0:64]
ganga1980 marked this conversation as resolved.
Show resolved Hide resolved
dcr_resource_id = f"/subscriptions/{subscription_id}/resourceGroups/{cluster_resource_group_name}/providers/Microsoft.Insights/dataCollectionRules/{dataCollectionRuleName}"

# first get the association between region display names and region IDs (because for some reason
Expand Down