Leap 42.2 is EOL and has been replaced by 42.3
This commit also simplifies some of the logic in checking for suse versions.
openSUSE 13.X is no longer supported and hasn't been for some time, so we
don't need to worry about checking for those versions any longer. The script
will bail out at the `__check_end_of_life_versions` functions early on in the
install process.
This is a new requirement in recent versions of shellcheck. This commit
fixes the following shellcheck error:
- SC2181: Check exit code directly with e.g. 'if mycmd;', not indirectly with $?.
Fixes the following shellcheck violations:
- SC2233: Remove superfluous (..) around condition.
- SC2235: Use { ..; } instead of (..) to avoid subshell overhead.
Stable installs work fine, but git installs need an additional package
to be installed (python3-setuptools). Otherwise, the script fails with
the following error:
```
* INFO: Running install_ubuntu_git()
Traceback (most recent call last):
File "setup.py", line 24, in <module>
import distutils.dist
ModuleNotFoundError: No module named 'distutils.dist'
```
The functionality for the "Z" option was removed a while ago, but
the letter was never removed from the opt list. This change fixes the
following shellcheck warning:
SC2213: getopts specified -Z, but it's not handled by this 'case'.
The version of shellcheck that was previously running on bootstrap PRs
was out of date and not catching the fact that the VIRTUAL_ENV variable
didn't exist. That variable should be _VIRTUALENV_DIR instead.
This commit adds a warning when a pre-existing saltstack.repo
on CentOS/RHEL causes the version argument to be ignored.
It also allows the -F (forced overwrite) option to override
this situation, overwriting the saltstack.repo file, and
thus installing the specified version.
Resolves#1209.
The bootstrap-salt.sh script uses a "bashism" for the sleep command.
Bash allows real numbers as sleep time, but other POSIX shell
interpreters only support an integer as parameter. Thus raise the sleep
timeout from 0.1 to 1 second.
The git commits baa54a64, acbd9842, 1aea3037, and 03186a6d that
introduce the sleep commands do not explain why a sleep command is used
in the code. You might be able to remove the sleep command completely.
Bug-Debian: https://bugs.debian.org/772406
Tornado 5.0 is not compatible with Salt at this time. For now, install
an older version until Salt is fixed for newer versions of tornado.
See https://github.com/saltstack/salt/issues/45790 for more information.
Fixes#1202
Set the mirror by overwriting the installurl file which can only
contain a single line so the original behaviour of appending
might not have worked reliably.
The user can pass '-r' to disable setting the repos already to
opt-out of this behaviour.