Details
-
Feature
-
Status: Released (View Workflow)
-
Medium
-
Resolution: Fixed
-
2.0.0
-
None
Description
Current Situation
- The JS7 provides
- a start script for Controller and Agent: controller.sh, agent.sh
- an instance start script for Controller and Agents: controller_instance.sh, agent_<port>.sh
- a kill script for running tasks with Agents: kill_task.sh
- The above scripts are roughly compatible for a number of Unix environments, however, support for specific operating systems and shell versions is not clearly defined.
Desired Behavior
- All shell scripts are re-written for full posix-compatibility
- Supported OS shells include: current versions of ksh, bash, zsh, dash
- Supported OS products include
- OS in scope of testing by SOS: CentOS/RedHat, Ubuntu, Oracle Linux, Amazon Linux, AIX, MacOS
- OS out of scope of testing by SOS: Alma Linux, Rocky Linux
- "out of scope" means that SOS will not actively test such platforms but will apply required changes if indicated by the JS7 community.
- Shell scripts make use of traps for cleanup of temporary files and environment variables.
- Quoting: extensive quoting of variables
- Specific commands are used in a compatible way:
- Compatible use of grep: instead of egrep use grep -E
- Compatible use of tar: instead of tar -xvzf use gzip -c -d < ... | tar -xf - -C ...
- Generally stick to recommendations from
- Portable Shell Programming: https://www.gnu.org/savannah-checkouts/gnu/autoconf/manual/autoconf-2.71/html_node/Portable-Shell.html
- Shell Check: https://www.shellcheck.net/