Skip to content

Commit bd80892

Browse files
committed
PE-38219 - Installer - Windows as Jump host support - fixing os detection
1 parent 66f40b9 commit bd80892

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

plans/util/retrieve_and_upload.pp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,9 @@
3030
# lint:endignore
3131

3232
$operating_system = run_task('peadm::os_identification', 'local://localhost')
33-
$os_string = $operating_system.first.value['osfamily']
33+
$os_string =$operating_system.first.value['_output']
3434

35-
if os_string == 'windows' {
35+
if 'windows' in $os_string {
3636
$exists = run_command("[System.IO.File]::Exists('${local_path}')", 'local://localhost')
3737
if $exists.first['stdout'].chomp == 'false' {
3838
run_task('peadm::download', 'local://localhost',

tasks/os_identification.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ try {
1111
$osfamily = "unknown"
1212
}
1313

14-
return @{ osfamily = $osfamily }
14+
return $osfamily
1515
}catch {
1616
Write-Host "Installer failed with Exception: $_.Exception.Message"
1717
Exit 1

tasks/os_identification.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,5 +14,5 @@ else
1414
osfamily="unknown"
1515
fi
1616

17-
echo '{ "osfamily": "'$osfamily'" }'
17+
echo $osfamily
1818

0 commit comments

Comments
 (0)