Skip to content

Commit

Permalink
Add support to custom endpoints for Arc Autonomous (#218)
Browse files Browse the repository at this point in the history
  • Loading branch information
ms-hujia authored Aug 22, 2022
1 parent d292760 commit b1b985b
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -52,9 +52,17 @@ spec:
- name: MAC
value: "true"
- name: customEnvironment
value: "azurepubliccloud"
value: {{ required "customEnvironment is required when using monitoring account" .Values.customEnvironment | toString | trim | lower | quote }}
- name: OMS_TLD
value: "opinsights.azure.com"
{{- if eq .Values.customEnvironment "arcautonomous" }}
- name: customRegionalEndpoint
value: {{ required "customRegionalEndpoint is required when using monitoring account in Arc Autonomous" .Values.arcAutonomousSettings.customRegionalEndpoint | toString | trim | quote }}
- name: customGlobalEndpoint
value: {{ required "customGlobalEndpoint is required when using monitoring account in Arc Autonomous" .Values.arcAutonomousSettings.customGlobalEndpoint | toString | trim | quote }}
- name: customResourceEndpoint
value: {{ required "customResourceEndpoint is required when using monitoring account in Arc Autonomous" .Values.arcAutonomousSettings.customResourceEndpoint | toString | trim | quote }}
{{- end }}
{{- end }}
{{- if and (.Values.internalSettings.intEnvironment) (not .Values.useMonitoringAccount) }}
- name: ME_ADDITIONAL_FLAGS
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,17 @@ spec:
- name: MAC
value: "true"
- name: customEnvironment
value: "azurepubliccloud"
value: {{ required "customEnvironment is required when using monitoring account" .Values.customEnvironment | toString | trim | lower | quote }}
- name: OMS_TLD
value: "opinsights.azure.com"
{{- if eq .Values.customEnvironment "arcautonomous" }}
- name: customRegionalEndpoint
value: {{ required "customRegionalEndpoint is required when using monitoring account in Arc Autonomous" .Values.arcAutonomousSettings.customRegionalEndpoint | toString | trim | quote }}
- name: customGlobalEndpoint
value: {{ required "customGlobalEndpoint is required when using monitoring account in Arc Autonomous" .Values.arcAutonomousSettings.customGlobalEndpoint | toString | trim | quote }}
- name: customResourceEndpoint
value: {{ required "customResourceEndpoint is required when using monitoring account in Arc Autonomous" .Values.arcAutonomousSettings.customResourceEndpoint | toString | trim | quote }}
{{- end }}
{{- end }}
{{- if and (.Values.internalSettings.intEnvironment) (not .Values.useMonitoringAccount) }}
- name: ME_ADDITIONAL_FLAGS
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ azureResourceId: ""
# -- required & used only when useMonitoringAccount=true. This is the Azure region for the Kubernetes cluster that is going to be monitoring with this chart
azureResourceRegion: ""

# -- required & used only when useMonitoringAccount=true. This is the cloud name for the Kubernetes cluster that is going to be monitoring with this chart
customEnvironment: "azurepubliccloud"

scrapeTargets:
# -- when true, automatically scrape coredns service in the k8s cluster without any additional scrape config
coreDns: true
Expand Down Expand Up @@ -82,6 +85,12 @@ internalSettings:
intEnvironment: false
clusterOverride: false

# Do not change the below settings. They are reserved for Arc Autonomous
arcAutonomousSettings:
customRegionalEndpoint: ""
customGlobalEndpoint: ""
customResourceEndpoint: ""

# Only enable to view metrics being scraped for a short time. This can affect performance so it should not be enabled when not in use
debugMode:
enabled: false
Expand Down

0 comments on commit b1b985b

Please sign in to comment.