Skip to content

Commit f74d2f6

Browse files
committed
🔨 Add --root-user-action ignore to pip install commands in docker-entrypoint.sh
1 parent 3e42f05 commit f74d2f6

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

scripts/docker/docker-entrypoint.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ main()
131131
_pip_dns="certbot-dns-${_dns}"
132132
if [ "${_dns}" != "cloudflare" ]; then
133133
echo "[INFO]: Installing certbot DNS plugin -> ${_dns}..."
134-
pip install --timeout 60 --no-cache-dir "${_pip_dns}" || exit 2
134+
pip install --timeout 60 --no-cache-dir --root-user-action ignore "${_pip_dns}" || exit 2
135135
pip cache purge || exit 2
136136
echo -e "[OK]: Done.\n"
137137
fi
@@ -159,7 +159,7 @@ main()
159159
done
160160

161161
echo "[INFO]: Upgrading certbot..."
162-
pip install --timeout 60 --no-cache-dir --upgrade certbot || exit 2
162+
pip install --timeout 60 --no-cache-dir --root-user-action ignore --upgrade certbot || exit 2
163163
pip cache purge || exit 2
164164
echo -e "[OK]: Done.\n"
165165

@@ -174,7 +174,7 @@ main()
174174

175175
if [ ${_disable_renew} != true ]; then
176176
echo "[INFO]: Adding cron jobs..."
177-
echo -e "\n0 1 1 * * root /usr/local/bin/pip install --timeout 60 --no-cache-dir --upgrade certbot ${_pip_dns} >> /var/log/cron.pip.log 2>&1" >> /etc/crontab || exit 2
177+
echo -e "\n0 1 1 * * root /usr/local/bin/pip install --timeout 60 --no-cache-dir --root-user-action ignore --upgrade certbot ${_pip_dns} >> /var/log/cron.pip.log 2>&1" >> /etc/crontab || exit 2
178178
echo "0 2 * * 1 root /usr/local/bin/python -c 'import random; import time; time.sleep(random.random() * 3600)' && certbot renew -n --keep --max-log-backups 10 --deploy-hook '/usr/local/bin/certbot-deploy-hook.sh' ${_certbot_staging} ${_certbot_renew} >> /var/log/cron.certbot.log 2>&1 && /usr/local/bin/certbot-permissions.sh" >> /etc/crontab || exit 2
179179
echo -e "[OK]: Done.\n"
180180

0 commit comments

Comments
 (0)