ansible: Split files and artifact directories
authornicoo <nicoo@realraum.at>
Mon, 26 Nov 2018 21:45:10 +0000 (22:45 +0100)
committernicoo <nicoo@realraum.at>
Mon, 26 Nov 2018 21:47:01 +0000 (22:47 +0100)
- artifacts are assets generated by Ansible, not under version control
- files are static assets under version control

ansible/.gitignore
ansible/group_vars/all/main.yml
ansible/host_vars/torwaechter/main.yml

index e573ad5..d34e4c4 100644 (file)
@@ -4,4 +4,4 @@
 *.retry
 .*.sw?
 /.cache/
-/files/*/openwrt/
+/artifacts
index cd8f05d..d617779 100644 (file)
@@ -1,7 +1,10 @@
 ---
 # Build-related directories
+global_artifacts_dir: "{{ inventory_dir }}/artifacts"
 global_cache_dir: "{{ inventory_dir }}/.cache"
-global_artifacts_dir: "{{ inventory_dir }}/files"
+
+# Directory for static assets
+global_files_dir: "{{ inventory_dir }}/files"
 
 # Default credentials
 ## Root password; by default, undefined
index 2a2316f..016ec44 100644 (file)
@@ -31,11 +31,11 @@ openwrt_mixin:
 
   /usr/local/bin/authorized_keys.sh:
     mode: '0755'
-    file: "{{ global_artifacts_dir }}/{{ inventory_hostname }}/authorized_keys.sh"
+    file: "{{ global_files_dir }}/{{ inventory_hostname }}/authorized_keys.sh"
 
   /usr/local/bin/update-keys-from-stdin.sh:
     mode: '0755'
-    file: "{{ global_artifacts_dir }}/{{ inventory_hostname }}/update-keys-from-stdin.sh"
+    file: "{{ global_files_dir }}/{{ inventory_hostname }}/update-keys-from-stdin.sh"
 
   /etc/ssh/sshd_config:
     content: |