Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mauri870/fc4f3939167c16c4a32826919f4d1bfd to your computer and use it in GitHub Desktop.
Save mauri870/fc4f3939167c16c4a32826919f4d1bfd to your computer and use it in GitHub Desktop.
Unpause all paused agentes not in use in a Asterisk queue
#!/bin/sh
set -e
asterisk -rx "queue show ${1}"
grep '(paused) (Not in use)' |
awk '{$1=$1};1' |
cut -d' ' -f1 |
while read -r member
do
asterisk -rx "queue unpause member ${member} queue ${1}"
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment