Skip to content

Commit

Permalink
Test custom apt-daily timers
Browse files Browse the repository at this point in the history
Signed-off-by: Norman Ziegner <norman.ziegner@ufz.de>
  • Loading branch information
Norman Ziegner committed Jun 8, 2023
1 parent f393e28 commit 1a94b82
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
5 changes: 5 additions & 0 deletions molecule/default/molecule.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,11 @@ provisioner:
unattended_remove_unused_kernel_packages: true
unattended_only_on_ac_power: true
unattended_mail_sender: "jane@example.org"
unattended_systemd_timer_override: true
unattended_apt_daily_oncalendar: "*-*-* 11:08"
unattended_apt_daily_randomizeddelaysec: "0s"
unattended_apt_daily_upgrade_oncalendar: "*-*-* 11:31"
unattended_apt_daily_upgrade_randomizeddelaysec: "0s"
playbooks:
prepare: "prepare.yml"
check: "converge.yml"
Expand Down
8 changes: 8 additions & 0 deletions molecule/default/verify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,4 +68,12 @@
failed_when: "dry_run.rc != 0"
changed_when: false

- name: "Verify custom apt-daily timers" # noqa command-instead-of-shell
ansible.builtin.shell:
cmd: "{{ item }}"
changed_when: false
loop:
- 'systemctl list-timers apt-daily* | grep apt-daily.service | grep "11:08:00"'
- 'systemctl list-timers apt-daily* | grep apt-daily-upgrade.service | grep "11:31:00"'

...

0 comments on commit 1a94b82

Please sign in to comment.