Skip to content

Commit

Permalink
V11-walker timer
Browse files Browse the repository at this point in the history
Signed-off-by: desmax74 <[email protected]>
  • Loading branch information
desmax74 committed Sep 26, 2024
1 parent b6addc3 commit 43db3d2
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 24 deletions.
10 changes: 0 additions & 10 deletions roles/tpa_single_node/tasks/v11y/walker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,6 @@
ansible.builtin.set_fact:
dns_resolver: "{{ tpa_podman_network_results.network.subnets[0].gateway }}"

- name: Creates a v11y walker cron file under /etc/cron.d # 0 1 * * *
ansible.builtin.cron:
name: v11y cronjob
cron_file: v11-walker
hour: "1"
minute: "0"
user: root
job: "{{ lookup('ansible.builtin.template', 'configs/v11y_cronjob.sh') }}"
state: present

- name: Deploy v11walker Pod
ansible.builtin.include_tasks: install_manifest_cronjob.yml
vars:
Expand Down

This file was deleted.

1 change: 0 additions & 1 deletion roles/tpa_single_node/templates/configs/v11y_cronjob.sh

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,12 @@
Type=notify
Environment=PODMAN_SYSTEMD_UNIT=%n
TimeoutStartSec=600

ExecStart=/usr/bin/podman kube play --replace --service-container=true "{{ kube_play_file }}" --network "{{ podman_spec.network | default('podman') }}" --configmap "{{ podman_spec.configmap | default(omit) }}"

[Timer]
OnCalendar=hourly
AccuracySec=12h
Persistent=true

[Install]
WantedBy=default.target
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,13 @@
Type=notify
Environment=PODMAN_SYSTEMD_UNIT=%n
TimeoutStartSec=600

ExecStart=/usr/bin/podman kube play --replace --service-container=true "{{ kube_play_file }}" --network "{{ podman_spec.network | default('podman') }}"

[Timer]
#OnCalendar=hourly
OnCalendar=*:40/15 # The task will be executed every 15 minutes starting from the minute 0
AccuracySec=12h #maximum delay
Persistent=true

[Install]
WantedBy=default.target

0 comments on commit 43db3d2

Please sign in to comment.