Skip to content

Commit

Permalink
Merge branch 'master' of github.com:ironicbadger/ansible-role-snapraid
Browse files Browse the repository at this point in the history
  • Loading branch information
ironicbadger committed Apr 27, 2022
2 parents a8365a6 + e87b0f2 commit 681df0f
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ snapraid_runner_healthcheck_io_uuid: ""
snapraid_healthcheck_io_host: https://hc-ping.com

snapraid_runner_email_address: ""
snapraid_runner_gmail_pass: ""
snapraid_runner_email_pass: ""
snapraid_runner_email_address_from: "{{ snapraid_runner_email_address }}"
snapraid_runner_email_address_to: "{{ snapraid_runner_email_address }}"
snapraid_runner_email_sendon: "error"
Expand All @@ -31,7 +31,7 @@ snapraid_config_path: /etc/snapraid.conf
snapraid_runner_path: /opt/snapraid-runner/snapraid-runner
snapraid_runner_conf: "{{ snapraid_runner_path }}.conf"
snapraid_runner_bin: "{{ snapraid_runner_path }}.py"
snapraid_runner_command: "python3 {{ snapraid_runner_bin }} -c {{ snapraid_runner_conf }} {% if snapraid_runner_healthcheck_io_uuid %}| curl -fsS -m 10 --retry 5 -o /dev/null --data-binary '@-' {{ snapraid_healthcheck_io_host }}/{{ snapraid_runner_healthcheck_io_uuid }} > /dev/null{% endif %}"
snapraid_runner_command: "python3 {{ snapraid_runner_bin }} -c {{ snapraid_runner_conf }} {% if snapraid_runner_healthcheck_io_uuid %}&& curl -fsS -m 10 --retry 5 -o /dev/null {{ snapraid_healthcheck_io_host }}/{{ snapraid_runner_healthcheck_io_uuid }} > /dev/null{% endif %}"
snapraid_runner_scrub: true
snapraid_scrub_percent: 22
snapraid_scrub_age: 8
Expand Down
4 changes: 2 additions & 2 deletions tasks/cron.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
- name: Schedule snapraid sync
cron:
name: snapraid sync
job: snapraid sync {% if snapraid_sync_healthcheck_io_uuid %}| curl -fsS -m 10 --retry 5 -o /dev/null --data-binary "@-" {{ snapraid_healthcheck_io_host }}/{{ snapraid_sync_healthcheck_io_uuid }}{% endif %}
job: snapraid sync {% if snapraid_sync_healthcheck_io_uuid %}&& curl -fsS -m 10 --retry 5 -o /dev/null {{ snapraid_healthcheck_io_host }}/{{ snapraid_sync_healthcheck_io_uuid }}{% endif %}
user: root
weekday: "{{ snapraid_sync_schedule.weekday | default ('*') }}"
minute: "{{ snapraid_sync_schedule.minute | default ('0')}}"
Expand All @@ -13,7 +13,7 @@
- name: Schedule snapraid scrub
cron:
name: snapraid scrub
job: snapraid scrub --plan {{ snapraid_scrub_percent }} --older-than {{ snapraid_scrub_age }} {% if snapraid_scrub_healthcheck_io_uuid %}| curl -fsS -m 10 --retry 5 -o /dev/null --data-binary "@-" {{ snapraid_healthcheck_io_host }}/{{ snapraid_scrub_healthcheck_io_uuid }}{% endif %}
job: snapraid scrub --plan {{ snapraid_scrub_percent }} --older-than {{ snapraid_scrub_age }} {% if snapraid_scrub_healthcheck_io_uuid %}&& curl -fsS -m 10 --retry 5 -o /dev/null {{ snapraid_healthcheck_io_host }}/{{ snapraid_scrub_healthcheck_io_uuid }}{% endif %}
user: root
weekday: "{{ snapraid_scrub_schedule.weekday | default ('*') }}"
minute: "{{ snapraid_scrub_schedule.minute | default ('0')}}"
Expand Down
2 changes: 1 addition & 1 deletion templates/snapraid-runner.conf.j2
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ port = {{ snapraid_runner_smtp_port }}
; set to "true" to activate
ssl = {{ snapraid_runner_use_ssl }}
user = {{ snapraid_runner_email_address }}
password = {{ snapraid_runner_gmail_pass }}
password = {{ snapraid_runner_email_pass }}

[scrub]
; set to true to run scrub after sync
Expand Down

0 comments on commit 681df0f

Please sign in to comment.