Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adding support for running apt at container init
- Loading branch information
Showing
1 changed file
with
14 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
#!/bin/bash | ||
|
||
set -e | ||
|
||
if [ -n "$DEBBASE_NO_STARTUP_APT" ]; then | ||
echo "Running apt daily job at container start..." | ||
/usr/lib/apt/apt.systemd.daily | ||
echo "apt daily job complete; proceeding with container initialization." | ||
fi | ||
|
||
# /usr/lib/apt/apt.systemd.daily is called from /etc/cron.daily/apt-compat. | ||
# /lib/systemd/system/apt-daily{,-upgrade}.{service,timer} also call it, | ||
# with arguments to do things in two separate phases. With no args, | ||
# it does everything at once. |