From cf2128c092f6cdcdc0e988367b7896e5308125c8 Mon Sep 17 00:00:00 2001 From: Andrea Dell'Amico Date: Fri, 5 Aug 2016 15:33:44 +0200 Subject: [PATCH] d4science-ghn-cluster/group_vars/ckan_dev/all.yml: Enable the CKAN harvester on the dev instance. library/roles/ckan/ckan: Set the /var/lib/ckan permissions. --- ckan/ckan/defaults/main.yml | 3 ++- ckan/ckan/tasks/ckan.yml | 6 +++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/ckan/ckan/defaults/main.yml b/ckan/ckan/defaults/main.yml index c2e481a2..9cf77186 100644 --- a/ckan/ckan/defaults/main.yml +++ b/ckan/ckan/defaults/main.yml @@ -15,7 +15,8 @@ ckan_package_url: 'http://packaging.ckan.org/{{ ckan_deb_file }}' ckan_libdir: /usr/lib/ckan ckan_confdir: /etc/ckan/default ckan_virtenv: '{{ ckan_libdir }}/default' -ckan_file_storage_dir: /var/lib/ckan/dev +ckan_file_harvesting_dir: /var/lib/ckan +ckan_file_storage_dir: '{{ ckan_file_harvesting_dir }}/dev' ckan_config_file: '{{ ckan_confdir }}/production.ini' ckan_webapp_port: 8080 ckan_solr_port: 8983 diff --git a/ckan/ckan/tasks/ckan.yml b/ckan/ckan/tasks/ckan.yml index 2eaf0eae..c42bd6cd 100644 --- a/ckan/ckan/tasks/ckan.yml +++ b/ckan/ckan/tasks/ckan.yml @@ -15,7 +15,11 @@ tags: [ 'ckan', 'ckan_ini' ] - name: Create the base directory for the CKAN file storage - file: dest={{ ckan_file_storage_dir }} state=directory owner={{ apache_user }} mode=0700 + file: dest={{ ckan_file_storage_dir }} state=directory owner={{ apache_user }} group={{ ckan_shell_user }} mode=2770 + tags: ckan + +- name: Fix the CKAN harvesting storage permissions + file: dest={{ ckan_file_harvesting_dir }} state=directory owner={{ apache_user }} group={{ ckan_shell_user }} mode=2770 recurse=yes tags: ckan - name: authorization file for the psql command, if the database is on a remote server