index : builder | |
Archlinux32 build system | gitolite user |
summaryrefslogtreecommitdiff |
author | Erich Eckner <git@eckner.net> | 2019-06-28 09:06:29 +0200 |
---|---|---|
committer | Erich Eckner <git@eckner.net> | 2019-06-28 09:06:29 +0200 |
commit | 81ce0f9e99e7a11202a907ba9773a424475fc101 (patch) | |
tree | 8eaa177548da3befdeacc679af12c03cca43a651 | |
parent | faaff687c71809101943840bb0115e7000e6f606 (diff) |
-rwxr-xr-x | lib/load-configuration | 25 |
diff --git a/lib/load-configuration b/lib/load-configuration index f327550..e434b4b 100755 --- a/lib/load-configuration +++ b/lib/load-configuration @@ -198,3 +198,28 @@ if [ "${master_build_server_identity}" = "${work_dir}/.ssh/id_rsa" ] && \ mkdir -p "${master_build_server_identity%/*}" ssh-keygen -b4096 -f "${master_build_server_identity}" fi + +if ${i_am_the_master}; then + # shellcheck disable=SC2016 + { + printf 'INSERT INTO `command_log`(`command`,`parameters`,`shell`)' + printf ' VALUES (' + printf 'from_base64("%s"),' \ + "$( + printf '%s' "${0##*/}" | \ + base64 + )" + printf 'from_base64("%s"),' \ + "$( + printf '%s' "$*" | \ + base64 + )" + if tty -s; then + printf '1' + else + printf '0' + fi + printf ');\n' + } | \ + mysql_run_query 'unimportant' +fi |