Re: [Asterisk-Users] Re: Auto Logout from queue

2006-05-04 Thread Christopher Mayfield
it is two scripts an empty_queue.sh and a fill_queue.sh and a members script If you need intructions please tell me1047 $ cat empty_queue.sh#!/bin/bash# a script to remove everyone in the members script located in the same directory as this file
# to the Q 3901# can be called from a script#Local/[EMAIL PROTECTED]#Local/[EMAIL PROTECTED]#Local/[EMAIL PROTECTED]for wild in `/usr/sbin/asterisk -r -x show queue 3901| grep -a dynamic | awk '{ print $1 }'`;
 do /usr/sbin/asterisk -r -x remove queue member $wild from 3901| grep -a interface; done1048 $ cat fill_queue.sh#!/bin/bash# a script to add everyone in the members script located in the same directory as this file
# to the Q 3901# can be called from a script#Local/[EMAIL PROTECTED]#Local/[EMAIL PROTECTED]#Local/[EMAIL PROTECTED]for wild in `cat /home/cmayfield/members `; do /usr/sbin/asterisk -r -x add queue member $wild to 3901| grep -a interface;
 done1049 $ cat membersLocal/[EMAIL PROTECTED]Local/[EMAIL PROTECTED]1050 $ crontab -l#at 8:1 and 8:11 it will fill the queue and it is nondistructive1,11 8 * * 1-5 sh /home/cmayfield/fill_queue.sh | mail -s fill_queue 
[EMAIL PROTECTED]#at 5:31 and 5:36 it will empty the queue and it is nondistructive31,36 17 * * 1-5 sh /home/cmayfield/empty_queue.sh | mail -s empty_queue 
[EMAIL PROTECTED]On 5/2/06, Tomislav Parčina
 [EMAIL PROTECTED] wrote:In article 
[EMAIL PROTECTED], [EMAIL PROTECTED] says...
 that is a nice function I use a cronjob to logout everyone each evening if anyone wants that script I would love to provide it.Please send the script to the list.--Tomislav Parčina
Lama Computers SplitStinice 12, 21000 SplitTel.: +385(21)495148SIP: [EMAIL PROTECTED]e-mail: tparcina#lama.hrhttp://www.lama.hr
___--Bandwidth and Colocation provided by Easynews.com --Asterisk-Users mailing listTo UNSUBSCRIBE or update options visit:
 http://lists.digium.com/mailman/listinfo/asterisk-users-- $15.95/Month DreamHost Hosting SALE
60 GB Disk Storage, 1.6 TB TransferTransfer Increases 16 GB Weeklyhttp://www.dreamhost.com/r.cgi?ap0ught/shared/Use discount code caralena for $40 off all these low prices
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [Asterisk-Users] Re: Auto Logout from queue

2006-05-04 Thread Matt

Hrmmm.
I thought there was already an option in the queue.conf or agents.conf
file (Though can't remember off hand what) that would set an agent
logged out or on 'pause' if they did not answer a call.  No?

On 5/4/06, Christopher Mayfield [EMAIL PROTECTED] wrote:

it is two scripts an empty_queue.sh and a fill_queue.sh and a members script
If you need intructions please tell me

1047 $  cat empty_queue.sh
#!/bin/bash

# a script to remove everyone in the members script located in the same
directory as this file
# to the Q 3901
# can be called from a script

#Local/[EMAIL PROTECTED]
#Local/[EMAIL PROTECTED]
#Local/[EMAIL PROTECTED]

for wild in `/usr/sbin/asterisk -r -x show queue 3901| grep -a dynamic |
awk '{ print $1 }'`;
do
/usr/sbin/asterisk -r -x remove queue member $wild from 3901|
grep -a interface;
done

1048 $  cat fill_queue.sh
#!/bin/bash

# a script to add everyone in the members script located in the same
directory as this file
# to the Q 3901
# can be called from a script

#Local/[EMAIL PROTECTED]
#Local/[EMAIL PROTECTED]
#Local/[EMAIL PROTECTED]

for wild in `cat /home/cmayfield/members `;
do
/usr/sbin/asterisk -r -x add queue member $wild to 3901| grep -a
interface;
done

1049 $  cat members
Local/[EMAIL PROTECTED]
Local/[EMAIL PROTECTED]

1050 $  crontab -l
#at 8:1 and 8:11 it will fill the queue and it is nondistructive
1,11 8   *   *   1-5   sh /home/cmayfield/fill_queue.sh
| mail -s fill_queue [EMAIL PROTECTED]
#at 5:31 and 5:36 it will empty the queue and it is nondistructive
31,3617   *   *   1-5   sh
/home/cmayfield/empty_queue.sh | mail -s empty_queue [EMAIL PROTECTED]


On 5/2/06, Tomislav Parčina [EMAIL PROTECTED] wrote:
 In article 
[EMAIL PROTECTED],
[EMAIL PROTECTED] says...
  that is a nice function
  I use a cronjob to logout everyone each evening if anyone wants that
script
  I would love to provide it.

 Please send the script to the list.



 --
 Tomislav Parčina
 Lama Computers Split
 Stinice 12, 21000 Split
 Tel.: +385(21)495148
 SIP: [EMAIL PROTECTED]
 e-mail: tparcina#lama.hr
 http://www.lama.hr
 ___
 --Bandwidth and Colocation provided by Easynews.com --

 Asterisk-Users mailing list
 To UNSUBSCRIBE or update options visit:

http://lists.digium.com/mailman/listinfo/asterisk-users




--
$15.95/Month DreamHost Hosting SALE
60 GB Disk Storage, 1.6 TB Transfer
Transfer Increases 16 GB Weekly
http://www.dreamhost.com/r.cgi?ap0ught/shared/
Use discount code caralena for $40 off all these low prices
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:

http://lists.digium.com/mailman/listinfo/asterisk-users



___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users