fastd grep script

master
Niklas Yann Wettengel 4 years ago
parent 2874a4583e
commit f8dbb9f988

@ -0,0 +1,7 @@
#!/bin/sh
for file in /run/ff*.socket
do
echo $file
nc -U $file | jq -r '.peers | keys[] as $k | "\(.[$k] | .connection.mac_addresses[]) \(.[$k] | .address) \($k)"' | grep $1
done

@ -39,6 +39,20 @@
mode: 0744
with_items: "{{ sites }}"
- name: add fastd_grep script
copy:
src: fastd_grep.sh
dest: /root/fastd_grep.sh
mode: 0744
- name: install fastd_grep dependencies
pacman:
name:
- openbsd-netcat
- jq
state: present
- name: start and enable fastd service
systemd:
name: fastd@ff{{ item.name }}.service

Loading…
Cancel
Save