summaryrefslogtreecommitdiffstats
path: root/tasks
diff options
context:
space:
mode:
Diffstat (limited to 'tasks')
-rw-r--r--tasks/apt.yml9
-rw-r--r--tasks/network.yml1
-rw-r--r--tasks/webmap.yml35
3 files changed, 42 insertions, 3 deletions
diff --git a/tasks/apt.yml b/tasks/apt.yml
index 1023908..f17a2e4 100644
--- a/tasks/apt.yml
+++ b/tasks/apt.yml
@@ -5,8 +5,13 @@
- apt
- lsb-release
-- name: Remove /etc/apt/sources.list
- file: path=/etc/apt/sources.list state=absent
+# something keeps recreating (without content) it if we delete it, so we
+# leave it instead but ensure it's empty instead
+- name: Create empty /etc/apt/sources.list
+ copy: content=""
+ dest=/etc/apt/sources.list
+ owner=root group=root
+ mode=0644
notify:
- apt-get update
diff --git a/tasks/network.yml b/tasks/network.yml
index 1551f82..a02b07c 100644
--- a/tasks/network.yml
+++ b/tasks/network.yml
@@ -32,6 +32,7 @@
packages:
- systemd-resolved
- libnss-resolve
+ - libnss-myhostname
- name: Create directory /etc/systemd/resolved.conf.d
file: path=/etc/systemd/resolved.conf.d
diff --git a/tasks/webmap.yml b/tasks/webmap.yml
index 9e2c2f6..5f82d7f 100644
--- a/tasks/webmap.yml
+++ b/tasks/webmap.yml
@@ -108,6 +108,19 @@
owner=_webmap-download group=root
mode=0755
+- name: Create directory /var/cache/webmap/custom
+ file: path=/var/cache/webmap/custom
+ state=directory
+ owner=root group=root
+ mode=0755
+
+- name: Copy custom layers into /var/cache/webmap/custom
+ copy: src=webmap-tools/layers/custom/
+ dest=/var/cache/webmap/custom/
+ owner=root group=root
+ mode=0644
+ directory_mode=0755
+
- name: Copy webmap-download@.service
copy: src=etc/systemd/system/webmap-download@.service
dest=/etc/systemd/system/webmap-download@.service
@@ -118,7 +131,11 @@
- name: Enable webmap-download@.service
service: name=webmap-download@{{ item }}.service enabled=true
- with_items: "{{ webmap_layer_groups }}"
+ with_items: "{{ webmap_layer_groups | difference(webmap_layer_groups_nodownload) }}"
+
+- name: Disable some webmap-download@.service
+ service: name=webmap-download@{{ item }}.service enabled=false
+ with_items: "{{ webmap_layer_groups_nodownload }}"
- meta: flush_handlers
@@ -306,6 +323,7 @@
service: name=webmap-import@{{ item }}.service enabled=true
with_items: "{{ webmap_layer_groups }}"
+
- name: Build administrative-codes.json*
become: false
local_action:
@@ -313,6 +331,21 @@
chdir: ./webmap-tools/administrative-codes
target: all
+- name: Create directory /var/www/webmap/data
+ file: path=/var/www/webmap/data
+ state=directory
+ owner=root group=root
+ mode=0755
+
+- name: Copy /var/www/webmap/data/administrative-codes.json*
+ copy: src=./webmap-tools/administrative-codes/{{ item }}
+ dest=/var/www/webmap/data/{{ item }}
+ owner=root group=root
+ mode=0644
+ with_items:
+ - administrative-codes.json
+ - administrative-codes.json.br
+
- meta: flush_handlers