aboutsummaryrefslogtreecommitdiffstats
path: root/roles
diff options
context:
space:
mode:
authorEmil Renner Berthing <esmil@labitat.dk>2020-02-27 14:12:46 +0100
committerEmil Renner Berthing <esmil@labitat.dk>2020-02-27 14:13:01 +0100
commitbf5374dd9724ca511567941dff8d472ebda51420 (patch)
tree96ff3c48d7062bd91303f322442dca48fec17531 /roles
parentf1b1a9fd90056b2d42b2cb41e71af254e2c07268 (diff)
downloadlabitat-ansible-bf5374dd9724ca511567941dff8d472ebda51420.tar.gz
labitat-ansible-bf5374dd9724ca511567941dff8d472ebda51420.tar.xz
labitat-ansible-bf5374dd9724ca511567941dff8d472ebda51420.zip
raspbian: update for hash_behaviour = replace
Diffstat (limited to 'roles')
-rw-r--r--roles/doorputer/tasks/lockserver.yml3
-rw-r--r--roles/doorputer/vars/main.yml22
-rw-r--r--roles/jumbotron/vars/main.yml6
-rw-r--r--roles/raspbian-template/vars/main.yml2
-rw-r--r--roles/raspbian/vars/main.yml (renamed from roles/raspbian/defaults/main.yml)17
5 files changed, 32 insertions, 18 deletions
diff --git a/roles/doorputer/tasks/lockserver.yml b/roles/doorputer/tasks/lockserver.yml
index 033e80d..a9122d1 100644
--- a/roles/doorputer/tasks/lockserver.yml
+++ b/roles/doorputer/tasks/lockserver.yml
@@ -46,6 +46,8 @@
mode: 0700
- name: Create lockserver.ini
+ vars:
+ lockserver_conf: '{{ lockserver_conf_role|combine(lockserver_conf_secrets) }}'
ini_file:
path: '~doorman/.config/lockserver.ini'
section: "{{ item.key.split('.',1)[0] }}"
@@ -56,6 +58,7 @@
group: users
mode: 0600
with_dict: '{{ lockserver_conf }}'
+ when: lockserver_conf_secrets|length > 0
- name: Install lockserver service
copy:
diff --git a/roles/doorputer/vars/main.yml b/roles/doorputer/vars/main.yml
index e2fb021..4d7f336 100644
--- a/roles/doorputer/vars/main.yml
+++ b/roles/doorputer/vars/main.yml
@@ -1,15 +1,7 @@
---
hostname: 'doorputer'
-users:
- 'esmil': sudo
- 'ast': sudo
- 'flummer': sudo
- 'riiiis': sudo
- 'knielsen': sudo
- 'signout': sudo
-
-apt_sources:
+apt_sources_role:
raspbian:
components:
- main
@@ -17,14 +9,22 @@ apt_sources:
- non-free
- rpi
-apt_packages:
+apt_packages_role:
'git': present # to check out lockserver repo
# lockserver dependencies
'python3-serial': present
'sqlite3': present
-lockserver_conf:
+users:
+ 'esmil': sudo
+ 'ast': sudo
+ 'flummer': sudo
+ 'riiiis': sudo
+ 'knielsen': sudo
+ 'signout': sudo
+
+lockserver_conf_role:
'Database.Path': '/home/doorman/users.db'
'Serial.Device': '/dev/ttyUSB0'
'Daymode.GPIONumber': '2'
diff --git a/roles/jumbotron/vars/main.yml b/roles/jumbotron/vars/main.yml
index 1adadb0..9f357cc 100644
--- a/roles/jumbotron/vars/main.yml
+++ b/roles/jumbotron/vars/main.yml
@@ -1,10 +1,10 @@
---
hostname: 'jumbotron'
-resolved_conf:
+resolved_conf_role:
'Resolve.DNSSEC': 'yes'
-apt_sources:
+apt_sources_role:
raspbian:
components:
- main
@@ -12,7 +12,7 @@ apt_sources:
- non-free
- rpi
-apt_packages:
+apt_packages_role:
'logrotate': absent
'cron': absent
diff --git a/roles/raspbian-template/vars/main.yml b/roles/raspbian-template/vars/main.yml
index 27cf894..1232f79 100644
--- a/roles/raspbian-template/vars/main.yml
+++ b/roles/raspbian-template/vars/main.yml
@@ -1,7 +1,7 @@
---
hostname: 'raspbian-template'
-apt_sources:
+apt_sources_role:
raspbian:
components:
- main
diff --git a/roles/raspbian/defaults/main.yml b/roles/raspbian/vars/main.yml
index 0bb24bc..fb95833 100644
--- a/roles/raspbian/defaults/main.yml
+++ b/roles/raspbian/vars/main.yml
@@ -1,18 +1,29 @@
---
-journald_conf:
+journald_conf_default:
# don't write journal to sd-card,
'Journal.Storage': 'volatile'
# just keep the last 16M in memory
'Journal.RuntimeMaxUse': '16M'
'Journal.ForwardToSyslog': 'no'
-apt_repos:
+apt_repos_default:
raspbian:
# doesn't support https, psh
uri: 'http://raspbian.raspberrypi.org/raspbian'
suite: '{{ ansible_distribution_release }}'
-apt_packages:
+apt_packages_default:
+ # copied from debian role
+ 'netbase': present
+ 'apt-transport-https': present
+ 'dialog': present
+ 'libpam-systemd': present
+ 'libnss-myhostname': present
+ 'vim': present
+ 'deborphan': present
+ 'openssh-server': present
+ 'sudo': present
+
# remove all this crap
'vim-tiny': absent
'mountall': absent