User Story
If you don't have permissions over the $rootdir folder itself, but only the relevant contents of $rootdir, updates will fail because sed attempts to drop temporary files into this folder. In addition to this, when an update fails at this section, the backup previously made is not restored to $rootdir which causes the gameserver.sh to report an invalid gameserver:
[ FAIL ] unknown game server
Basic info
- Distro: All
- Game: N/A
- Command: update
- LinuxGSM version: <= v20.5.0
Further Information
The bug occurs because we don't utilize $tmpdir to sed our changes, additionally we do not restore the backup previously created here.
To Reproduce
Steps to reproduce the behaviour:
- Set permissions such that you have the required permissions for all LGSM files and folders but not the root directory itself.
- Launch an update
gameserver.sh becomes invalid and update fails.
Expected behaviour
At the very least the backup should be restored in this case, but it is trivial to remove the case entirely by utilizing the $tmpdir rather than the $rootdir for sed changes.
User Story
If you don't have permissions over the
$rootdirfolder itself, but only the relevant contents of$rootdir, updates will fail becausesedattempts to drop temporary files into this folder. In addition to this, when an update fails at this section, the backup previously made is not restored to$rootdirwhich causes thegameserver.shto report an invalid gameserver:[ FAIL ] unknown game serverBasic info
Further Information
The bug occurs because we don't utilize
$tmpdirtosedour changes, additionally we do not restore the backup previously created here.To Reproduce
Steps to reproduce the behaviour:
gameserver.shbecomes invalid and update fails.Expected behaviour
At the very least the backup should be restored in this case, but it is trivial to remove the case entirely by utilizing the
$tmpdirrather than the$rootdirforsedchanges.