Sunil Mohan Adapa 2ceb80607a
setup: Perform package operations immediately on trigger
- Operations triggered by FreedomBox service itself such 'apt-get update' and
'apt-get install' don't cause the package operations (post-install and
post-update) to get triggered. This is due to recent implementation of a check
with the FREEDOMBOX_INVOKED environment variable. So, it fairly safe to attempt
these operations immediately as they would have been invoked from outside.

- In one case, when unattended-upgrades is triggered it could lead to
post-install trigger getting triggered too quickly. But this only leads the
operation detecting that apt is busy and performing the long wait immediately
after.

- In case of distribution upgrade, this could mean simpler reasoning and less
wait time.

Tests:

- When a package is installed, post-dpkg operations are triggered and completed
immediately. However, another apt process immediately takes lock, this results
in a waiting period.

- When a 'apt update' is run, update operations are triggered and completed
immediately.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
2025-04-07 20:59:17 -04:00
..
2025-04-06 16:46:44 +02:00
2025-03-25 10:09:23 -04:00
2024-12-25 12:25:05 +02:00