summaryrefslogtreecommitdiff
path: root/roles
diff options
context:
space:
mode:
Diffstat (limited to 'roles')
-rwxr-xr-xroles/apps/coturn/contrib/turn-create-time-limited-user.sh15
-rw-r--r--roles/core/base/tasks/main.yml2
-rw-r--r--roles/core/sshd/tasks/main.yml4
-rw-r--r--roles/installer/debian/preseed/tasks/main.yml2
-rw-r--r--roles/reboot-and-wait/tasks/main.yml2
5 files changed, 17 insertions, 8 deletions
diff --git a/roles/apps/coturn/contrib/turn-create-time-limited-user.sh b/roles/apps/coturn/contrib/turn-create-time-limited-user.sh
new file mode 100755
index 00000000..0d4947fc
--- /dev/null
+++ b/roles/apps/coturn/contrib/turn-create-time-limited-user.sh
@@ -0,0 +1,15 @@
+#!/bin/sh
+
+if [ -z "$1" ]; then
+ echo "Usage: $0 <expiry-seconds>"
+ exit 1
+fi
+
+
+secret="{{ coturn_auth_secret }}"
+
+time=$(date +%s)
+username=$(( $time + $1 ))
+
+echo username: "$username"
+echo password: $(echo -n "$username" | openssl dgst -binary -sha1 -hmac "$secret" | openssl base64)
diff --git a/roles/core/base/tasks/main.yml b/roles/core/base/tasks/main.yml
index 5484a3a6..73d85993 100644
--- a/roles/core/base/tasks/main.yml
+++ b/roles/core/base/tasks/main.yml
@@ -17,8 +17,6 @@
line: "startup_message off"
dest: /etc/screenrc
mode: 0644
- tags:
- - screen
- name: install htop config (1/2)
loop:
diff --git a/roles/core/sshd/tasks/main.yml b/roles/core/sshd/tasks/main.yml
index ef0e9a81..f07bef54 100644
--- a/roles/core/sshd/tasks/main.yml
+++ b/roles/core/sshd/tasks/main.yml
@@ -27,7 +27,7 @@
notify: restart ssh
- name: limit allowed users
- when: not sshd_allow_any_user
+ when: not sshd_allow_any_user | bool
lineinfile:
dest: /etc/ssh/sshd_config
regexp: "^AllowUsers\\s"
@@ -35,7 +35,7 @@
notify: restart ssh
- name: allow any user
- when: sshd_allow_any_user
+ when: sshd_allow_any_user | bool
lineinfile:
dest: /etc/ssh/sshd_config
regexp: "^AllowUsers\\s"
diff --git a/roles/installer/debian/preseed/tasks/main.yml b/roles/installer/debian/preseed/tasks/main.yml
index 599d9ddb..2934ca1b 100644
--- a/roles/installer/debian/preseed/tasks/main.yml
+++ b/roles/installer/debian/preseed/tasks/main.yml
@@ -53,5 +53,3 @@
etc/systemd/
etc/systemd/network/
etc/systemd/network/90-namepolicy.link
- tags:
- - skip_ansible_lint
diff --git a/roles/reboot-and-wait/tasks/main.yml b/roles/reboot-and-wait/tasks/main.yml
index 18ae2703..e648f0af 100644
--- a/roles/reboot-and-wait/tasks/main.yml
+++ b/roles/reboot-and-wait/tasks/main.yml
@@ -3,8 +3,6 @@
async: 1
poll: 0
ignore_errors: true
- tags:
- - skip_ansible_lint
- name: waiting for host to come back
wait_for_connection: