Fix sudo setup for containers with broken lists

This commit is contained in:
Shivam Mathur
2023-01-21 08:06:21 +05:30
parent bbc65d999a
commit dd0115673c

View File

@ -2,7 +2,7 @@
add_sudo() {
if ! command -v sudo >/dev/null; then
check_package sudo || apt-get update
apt-get install -y sudo
apt-get install -y sudo || (apt-get update && apt-get install -y sudo)
fi
}