Skip to content

Commit

Permalink
feat: ajoute le cron pour l'envoi du sondage initial par sms + refact…
Browse files Browse the repository at this point in the history
…o l'outil d'envoi d'email
  • Loading branch information
Shamzic committed Nov 10, 2023
1 parent a22c139 commit 07cc5c0
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion roles/bootstrap/tasks/setup_cron.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,19 @@
job: >-
(cd {{ repository_folder }} &&
{{ envvar_prefix }} /usr/bin/node
./dist-server/backend/lib/email.js send initial-survey
./dist-server/backend/lib/email-sending-tool.js send initial-survey
--multiple 1000 >> /var/log/{{ server_user_name }}/{{ item.name }}_emails.log 2>&1)
- name: Add a cron job to send initial survey by sms
become_user: "{{ server_user_name }}"
ansible.builtin.cron:
name: send initial survey sms for {{ item.name }}
minute: "8"
hour: "4"
job: >-
(cd {{ repository_folder }} &&
{{ envvar_prefix }} /usr/bin/node
./dist-server/backend/lib/sms-sending-tool.js send initial-survey
--multiple 1000 >> /var/log/{{ server_user_name }}/{{ item.name }}_sms.log 2>&1)
- name: Add a cron job to send email
become_user: "{{ server_user_name }}"
ansible.builtin.cron:
Expand Down

0 comments on commit 07cc5c0

Please sign in to comment.