Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cron-apt remove action should be after security #4011

Merged
merged 1 commit into from Jan 5, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions install_files/ansible-base/roles/common/tasks/cron_apt.yml
Expand Up @@ -34,8 +34,8 @@
# this logic for existing installs.
- name: Configure cron-apt to remove vanilla kernels if they are installed.
copy:
src: 1-remove
dest: /etc/cron-apt/action.d/1-remove
src: 9-remove
dest: /etc/cron-apt/action.d/9-remove
tags:
- apt
- cron-apt
Expand Down
5 changes: 5 additions & 0 deletions install_files/securedrop-config/DEBIAN/postinst
Expand Up @@ -34,6 +34,11 @@ case "$1" in
fi
remove_2fa_tty_req
disable_upgrade_prompt
# Remove cron-apt action should occur after security upgrades to avoid breaking
# automatic upgrades (see issue #4003)
if [ -f "/etc/cron-apt/action.d/1-remove" ]; then
rm /etc/cron-apt/action.d/1-remove
fi
;;

abort-upgrade|abort-remove|abort-deconfigure)
Expand Down
2 changes: 1 addition & 1 deletion molecule/testinfra/staging/common/test_cron_apt.py
Expand Up @@ -76,7 +76,7 @@ def test_cron_apt_delete_vanilla_kernels(File):
Ensure cron-apt removes generic linux image packages when installed.
"""

f = File('/etc/cron-apt/action.d/1-remove')
f = File('/etc/cron-apt/action.d/9-remove')
assert f.is_file
assert f.user == "root"
assert oct(f.mode) == "0644"
Expand Down