mirror of
https://github.com/hackacad/bastille.git
synced 2025-12-24 11:12:12 +01:00
common: Load config as variable
This commit is contained in:
@@ -44,13 +44,8 @@ bastille_root_check() {
|
||||
}
|
||||
|
||||
load_config() {
|
||||
_user="$(id -un)"
|
||||
if [ "${_user}" != "root" ] && [ -r "/usr/local/etc/bastille/bastille_${_user}.conf" ]; then
|
||||
# shellcheck disable=SC1090
|
||||
. /usr/local/etc/bastille/bastille_${_user}.conf
|
||||
else
|
||||
. /usr/local/etc/bastille/bastille.conf
|
||||
fi
|
||||
# shellcheck disable=SC1090
|
||||
. ${BASTILLE_CONFIG}
|
||||
}
|
||||
|
||||
# Load configuration file
|
||||
|
||||
Reference in New Issue
Block a user