Please show MOTD in containers' shell started without PAM printing MOTD
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
update-motd |
New
|
Undecided
|
Unassigned | ||
update-motd (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned | ||
Eoan |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
[Impact]
* Users of containers may never see the MOTD of the container if they are always to the container's shell without PAM being involved.
* MOTD contains important information about the system's health including the security updates to be installed thus it is desired to show MOTD in container shells, too.
* The fix is creating a snippet in /etc/profile.d which shows, but not necessarily updates MOTD once a day.
[Test Case]
* Install show-motd in an LXC container.
* Observe MOTD shown when starting the container shell with
$ lxc shell <container name>
[Regression Potential]
* The new functionality is added in a new package, shown-motd, thus users of update-motd should not observe any regression.
* The change in update-motd is adding the --show-only optional option. Both the new and old code patch is exercised in autopkgtest and should be safe.
[Other Info]
* The fix relies on PAM setting MOTD_SHOWN=pam to avoid printing MOTD twice.
description: | updated |
This bug was fixed in the package update-motd - 3.6-0ubuntu4
---------------
update-motd (3.6-0ubuntu4) focal; urgency=medium
* update-motd.sh: Don't source, but run update-motd.
This fixes being dropped out of shell when update-motd exits
with nonzero value.
* update-motd.sh: Don't misleadingly indicate that script is
running with set -e
* update-motd.sh: Don't set "stamp" and eval_gettext()
in /etc/profile.d script
-- Balint Reczey <email address hidden> Sat, 07 Dec 2019 10:25:10 +0100