*.retry
.*.sw?
/.cache/
-/files/*/openwrt/
+/artifacts
--- /dev/null
+# Beware! This file is rewritten by htop when settings are changed in the interface.
+# The parser is also very primitive, and not human-friendly.
+fields=0 48 17 18 38 39 40 2 46 47 49 1
+sort_key=46
+sort_direction=1
+hide_threads=0
+hide_kernel_threads=1
+hide_userland_threads=0
+shadow_other_users=0
+show_thread_names=0
+show_program_path=1
+highlight_base_name=1
+highlight_megabytes=1
+highlight_threads=1
+tree_view=1
+header_margin=1
+detailed_cpu_time=0
+cpu_count_from_zero=0
+update_process_names=0
+account_guest_in_cpu_meter=0
+color_scheme=0
+delay=15
+left_meters=AllCPUs Memory Swap
+left_meter_modes=1 1 1
+right_meters=Tasks LoadAverage Uptime
+right_meter_modes=2 2 2
{{ key }}
{% endfor %}
- /root/.config/htop/htoprc:
- content: |
- # Beware! This file is rewritten by htop when settings are changed in the interface.
- # The parser is also very primitive, and not human-friendly.
- fields=0 48 17 18 38 39 40 2 46 47 49 1
- sort_key=46
- sort_direction=1
- hide_threads=0
- hide_kernel_threads=1
- hide_userland_threads=0
- shadow_other_users=0
- show_thread_names=0
- show_program_path=1
- highlight_base_name=1
- highlight_megabytes=1
- highlight_threads=1
- tree_view=1
- header_margin=1
- detailed_cpu_time=0
- cpu_count_from_zero=0
- update_process_names=0
- account_guest_in_cpu_meter=0
- color_scheme=0
- delay=15
- left_meters=AllCPUs Memory Swap
- left_meter_modes=1 1 1
- right_meters=Tasks LoadAverage Uptime
- right_meter_modes=2 2 2
+ /etc/htoprc:
+ file: "{{ global_files_dir }}/common/htoprc"
openwrt_uci:
---
# 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
/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: |
when: ansible_distribution == "Ubuntu"
-- name: install zshrc
- with_items:
- - src: "zprofile"
- dest: "/etc/zsh/zprofile"
- - src: "zshrc"
- dest: "/etc/zsh/zshrc"
- - src: "zshrc.skel"
- dest: "/etc/skel/.zshrc"
- copy:
- src: "{{ item.src }}"
- dest: "{{ item.dest }}"
- mode: 0644
-
- name: set root default shell to zsh
user:
name: root
dest: /etc/adduser.conf
regexp: "^#?{{ item.key }}="
line: "{{ item.key }}={{ item.value }}"
+
+- name: Deploy default configuration for tools
+ with_dict:
+ /etc/htoprc: "{{ global_files_dir }}/common/htoprc"
+
+ /etc/zsh/zprofile: zprofile
+ /etc/zsh/zshrc: zshrc
+ /etc/skel/.zshrc: zshrc.skel
+
+ loop_control:
+ label: "{{ item.key }}"
+ copy:
+ mode: 0644
+ src: "{{ item.value }}"
+ dest: "{{ item.key }}"