Compare commits

..

1 Commits

Author SHA1 Message Date
CanbiZ
f2611061fc kimai: Set global SQL mode to empty in install script 2025-10-30 12:02:29 +01:00
2 changed files with 1 additions and 45 deletions

View File

@@ -33,6 +33,7 @@ MYSQL_VERSION=$(mariadb --version | grep -oE '[0-9]+\.[0-9]+\.[0-9]+')
$STD mariadb -u root -e "CREATE DATABASE $DB_NAME;"
$STD mariadb -u root -e "CREATE USER '$DB_USER'@'localhost' IDENTIFIED BY '$DB_PASS';"
$STD mariadb -u root -e "GRANT ALL ON $DB_NAME.* TO '$DB_USER'@'localhost'; FLUSH PRIVILEGES;"
$STD mariadb -u root -e "SET GLOBAL sql_mode='';"
{
echo "Kimai-Credentials"
echo "Kimai Database User: $DB_USER"

View File

@@ -368,51 +368,6 @@ run_container_safe() {
" || __handle_general_error "lxc-attach to CT $ct"
}
cleanup_lxc() {
msg_info "Cleaning up"
if is_alpine; then
$STD apk cache clean || true
rm -rf /var/cache/apk/*
else
$STD apt -y autoremove || true
$STD apt -y autoclean || true
$STD apt -y clean || true
fi
rm -rf /tmp/* /var/tmp/*
# Remove temp files created by mktemp/tempfile
find /tmp /var/tmp -type f -name 'tmp*' -delete 2>/dev/null || true
find /tmp /var/tmp -type f -name 'tempfile*' -delete 2>/dev/null || true
find /var/log -type f -exec truncate -s 0 {} +
# Python pip
if command -v pip &>/dev/null; then pip cache purge || true; fi
# Python uv
if command -v uv &>/dev/null; then uv cache clear || true; fi
# Node.js npm
if command -v npm &>/dev/null; then npm cache clean --force || true; fi
# Node.js yarn
if command -v yarn &>/dev/null; then yarn cache clean || true; fi
# Node.js pnpm
if command -v pnpm &>/dev/null; then pnpm store prune || true; fi
# Go
if command -v go &>/dev/null; then go clean -cache -modcache || true; fi
# Rust cargo
if command -v cargo &>/dev/null; then cargo clean || true; fi
# Ruby gem
if command -v gem &>/dev/null; then gem cleanup || true; fi
# Composer (PHP)
if command -v composer &>/dev/null; then composer clear-cache || true; fi
if command -v journalctl &>/dev/null; then
$STD journalctl --rotate
$STD journalctl --vacuum-time=10m
fi
msg_ok "Cleaned"
}
check_or_create_swap() {
msg_info "Checking for active swap"