From 57eb9b4f8f8c49092dc5151729c9d086f1ff6a2c Mon Sep 17 00:00:00 2001 From: Kevin Fenzi Date: Tue, 13 Oct 2015 20:15:57 +0000 Subject: [PATCH] Tweak infinoted config a bit more. Make sync 60 seconds instead of 10 add a handler to restart on config changes. --- handlers/restart_services.yml | 3 +++ roles/infinote/tasks/main.yml | 1 + roles/infinote/templates/infinoted.conf | 5 +---- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/handlers/restart_services.yml b/handlers/restart_services.yml index 28df763f03..4ad69cdc68 100644 --- a/handlers/restart_services.yml +++ b/handlers/restart_services.yml @@ -192,3 +192,6 @@ - name: restart autocloud service: name=autocloud state=restarted + +- name: restart infinoted + service: name=infinoted state=restarted diff --git a/roles/infinote/tasks/main.yml b/roles/infinote/tasks/main.yml index a4dcbf3aea..5bd6925238 100644 --- a/roles/infinote/tasks/main.yml +++ b/roles/infinote/tasks/main.yml @@ -89,6 +89,7 @@ - name: add config file for infinoted template: src=infinoted.conf dest=/etc/xdg/infinoted.conf + notify: restart infinoted tags: - infinote - config diff --git a/roles/infinote/templates/infinoted.conf b/roles/infinote/templates/infinoted.conf index c9d034995a..0afdfbc2c7 100644 --- a/roles/infinote/templates/infinoted.conf +++ b/roles/infinote/templates/infinoted.conf @@ -10,13 +10,10 @@ password={{ infinotepassword }} [autosave] interval=60 -# TODO: write git hook. https://github.com/gobby/gobby/wiki/PluginAutosave -#hook= [directory-sync] directory=/srv/web/infinote -interval=10 -# TODO: write git hook. https://github.com/gobby/gobby/wiki/PluginDirectorySync +interval=60 hook=/usr/local/bin/infinoted-git-commit [logging]