[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lmi-commits] [lmi] master 088edcf 2/2: Work around "root is not in the
From: |
Greg Chicares |
Subject: |
[lmi-commits] [lmi] master 088edcf 2/2: Work around "root is not in the sudoers file" |
Date: |
Mon, 18 May 2020 17:59:17 -0400 (EDT) |
branch: master
commit 088edcf3f1f30aee3ea2ac3e3b47b4aef6040e65
Author: Gregory W. Chicares <address@hidden>
Commit: Gregory W. Chicares <address@hidden>
Work around "root is not in the sudoers file"
See:
https://lists.nongnu.org/archive/html/lmi/2020-05/msg00030.html
et seqq.
---
install_redhat.sh | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/install_redhat.sh b/install_redhat.sh
index e7acf93..206e05b 100755
--- a/install_redhat.sh
+++ b/install_redhat.sh
@@ -182,7 +182,8 @@ mount --bind /srv/cache_for_lmi
/srv/chroot/"${CHRTNAME}"/srv/cache_for_lmi
cp -a lmi_setup_*.sh /tmp/schroot_env /srv/chroot/${CHRTNAME}/tmp
schroot --chroot=${CHRTNAME} --user=root --directory=/tmp
./lmi_setup_20.sh
schroot --chroot=${CHRTNAME} --user=root --directory=/tmp
./lmi_setup_21.sh
-sudo --user="${NORMAL_USER}"
./lmi_setup_30.sh
+# Use su instead of sudo on a server where root is not a sudoer.
+su "${NORMAL_USER}"
./lmi_setup_30.sh
schroot --chroot=${CHRTNAME} --user="${NORMAL_USER}" --directory=/tmp
./lmi_setup_40.sh
schroot --chroot=${CHRTNAME} --user="${NORMAL_USER}" --directory=/tmp
./lmi_setup_41.sh
schroot --chroot=${CHRTNAME} --user="${NORMAL_USER}" --directory=/tmp
./lmi_setup_42.sh