server-install-script-samples icon indicating copy to clipboard operation
server-install-script-samples copied to clipboard

Linux script assumes default shell is compatible (bash)

Open mojibake-umd opened this issue 6 years ago • 0 comments

When using SU at lines 565 and 614 SU will use the default shell, which if it is not bash (maybe sh also works) it is likely to fail. In our case default shell is tsch which fails with errors like "Missing name for redirect. " during the setup part of the script...

A work around for us was to explicitly set the shell for SU like 'su -s /usr/bin/bash -c "set -a && source <(cat ${confwild}) .....' on lines 565 and 614.

Suggested fix is detecting compatible shells, and passing to su -s, or write script in more portable fashion.

https://github.com/tableau/server-install-script-samples/blob/5aae1715980868e9f84b2691b4aa5b5c7ce0a52e/linux/automated-installer/automated-installer#L565 https://github.com/tableau/server-install-script-samples/blob/5aae1715980868e9f84b2691b4aa5b5c7ce0a52e/linux/automated-installer/automated-installer#L614

mojibake-umd avatar Feb 11 '19 19:02 mojibake-umd