Skip to content

Commit

Permalink
Merge pull request #159 from betagouv/hotfix_launching_email_config
Browse files Browse the repository at this point in the history
Hotfix launching email config
  • Loading branch information
baptou12 authored Sep 28, 2023
2 parents a5e9e42 + 16ad06d commit 7b68fac
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions roles/bootstrap/tasks/setup_cron.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,22 @@
name: send initial survey emails for {{ item.name }}
minute: "8"
hour: "4"
job: |-
({{ envvar_prefix }} {{ repository_folder }}/backend/lib/email.sh >> /var/log/{{ server_user_name }}/{{ item.name }}_emails.log 2>&1)
job: >-
(cd {{ repository_folder }} &&
{{ envvar_prefix }} /usr/bin/node
./dist-server/backend/lib/email.js send initial-survey
--multiple 1000 >> /var/log/{{ server_user_name }}/{{ item.name }}_emails.log 2>&1)
- name: Add a cron job to send email
become_user: "{{ server_user_name }}"
ansible.builtin.cron:
name: send tous-a-bord emails for {{ item.name }}
minute: "2"
hour: "9"
job: |-
(cd {{ repository_folder }}/dist-server/backend/lib/ && {{ envvar_prefix }} /usr/bin/node ./email.js send tous-a-bord-notification --multiple 100)
job: >-
(cd {{ repository_folder }} &&
{{ envvar_prefix }} /usr/bin/node
./dist-server/backend/lib/email.js send tous-a-bord-notification
--multiple 100 >> /var/log/{{ server_user_name }}/{{ item.name }}_emails_tous_a_bord.log 2>&1)
- name: Add a cron job to anonymize Simulation and Followup data collections
become_user: "{{ server_user_name }}"
ansible.builtin.cron:
Expand Down

0 comments on commit 7b68fac

Please sign in to comment.