File tree Expand file tree Collapse file tree 2 files changed +19
-3
lines changed Expand file tree Collapse file tree 2 files changed +19
-3
lines changed Original file line number Diff line number Diff line change 6
6
[string ]$with_fluentd = " true" ,
7
7
[string ]$with_msi_uninstall_comments = " " ,
8
8
[string ]$api_url = " https://api.${realm} .signalfx.com" ,
9
- [string ]$ingest_url = " https://ingest.${realm} .signalfx.com"
9
+ [string ]$ingest_url = " https://ingest.${realm} .signalfx.com" ,
10
+ [string ]$with_svc_args = " "
10
11
)
11
12
12
13
$ErrorActionPreference = ' Stop'
@@ -96,3 +97,18 @@ if ($installed_version -gt [Version]"0.97.0.0") {
96
97
If (! (Test-Path - Path " ${Env: ProgramData} \Splunk\OpenTelemetry Collector\*_config.yaml" )) {
97
98
throw " No config files found in ${Env: ProgramData} \Splunk\OpenTelemetry Collector these files are expected after the install"
98
99
}
100
+
101
+ $svc_commandline = " "
102
+ try {
103
+ $svc_commandline = Get-ItemPropertyValue - Path " HKLM:\SYSTEM\CurrentControlSet\Services\splunk-otel-collector" - Name " ImagePath"
104
+ } catch {
105
+ throw " Failed to retrieve the service command line from the registry."
106
+ }
107
+
108
+ if ($with_svc_args -ne " " ) {
109
+ if (-not $svc_commandline.EndsWith ($with_svc_args )) {
110
+ throw " Service command line does not match the expected arguments. Found: '$svc_commandline ', Expected to end with: '$with_svc_args '"
111
+ } else {
112
+ Write-Host " Service command line matches the expected arguments."
113
+ }
114
+ }
Original file line number Diff line number Diff line change 37
37
run : |
38
38
$ErrorActionPreference = 'Stop'
39
39
$env:VERIFY_ACCESS_TOKEN = "false"
40
- .\packaging\installer\install.ps1 -access_token "testing123" -realm "test" -mode "${{ matrix.MODE }}" -memory "256" -with_fluentd $${{ matrix.WITH_FLUENTD }} -msi_public_properties "ARPCOMMENTS=`"Installed via install.ps1`""
40
+ .\packaging\installer\install.ps1 -access_token "testing123" -realm "test" -mode "${{ matrix.MODE }}" -memory "256" -with_fluentd $${{ matrix.WITH_FLUENTD }} -msi_public_properties "ARPCOMMENTS=`"Installed via install.ps1`" COLLECTOR_SVC_ARGS=`"--discovery --set=processors.batch.timeout=10s`" "
41
41
Start-Sleep -s 30
42
- & ${{ github.workspace }}\.github\workflows\scripts\win-test-services.ps1 -mode "${{ matrix.MODE }}" -access_token "testing123" -realm "test" -memory "256" -with_fluentd "${{ matrix.WITH_FLUENTD }}" -with_msi_uninstall_comments "Installed via install.ps1"
42
+ & ${{ github.workspace }}\.github\workflows\scripts\win-test-services.ps1 -mode "${{ matrix.MODE }}" -access_token "testing123" -realm "test" -memory "256" -with_fluentd "${{ matrix.WITH_FLUENTD }}" -with_msi_uninstall_comments "Installed via install.ps1" -with_svc_args "--discovery --set=processors.batch.timeout=10s"
43
43
& ${{ github.workspace }}\.github\workflows\scripts\win-test-support-bundle.ps1 -mode "${{ matrix.MODE }}" -with_fluentd "${{ matrix.WITH_FLUENTD }}"
44
44
45
45
- name : splunk-otel-collector logs
You can’t perform that action at this time.
0 commit comments