>From looking at opensipsctl , it appears that the script only writes to the
DB and doesn't do any kind of fifo. I don't use subscribers much, so my
ability to offer suggestions is limited.
but if you look in opensipsctl, you'll see what it's doing, and I'm sure you
could just mimic that same bits in your higher level app. Be sure not to
miss the function calls in the script ie: "credentials"
---&<-- snip---
add)
if [ $# -ne 3 ] ; then
usage_subscriber
exit 1
fi
shift
credentials $1 $2
is_user $1
if [ $? -eq 0 ] ; then
minfo "user '$1' already exists"
exit 1
fi
set_user $1
check_alias $OSIPSUSER $OSIPSDOMAIN
if [ "$ALIAS_EXISTS" = "1" ] ; then
minfo "user '$1' already exists as alias"
exit 1
fi
if [ "$STORE_PLAINTEXT_PW" = "1" ] ; then
PASS="$2"
else
PASS=""
fi
QUERY="insert into $SUB_TABLE ($SUBSCRIBER_COLUMN,\
$REALM_COLUMN,$HA1_COLUMN,$HA1B_COLUMN,$PASSWORD_COLUMN) \
values
('$OSIPSUSER','$OSIPSDOMAIN','$HA1','$HA1B','$PASS');";
$DBCMD "$QUERY"
if [ $? -ne 0 ] ; then
merr "introducing the new user '$1' to the
database failed"
else
mecho "new user '$1' added"
fi
;;
On Thu, May 14, 2009 at 9:23 AM, Matti Zemack
<[email protected]>wrote:
> Hi all,
>
>
>
> How do you all add new subscribers to your systems?
>
> Today we do it by calling “opensipsctl add sdh...@asdjkhsd djhjhd” from
> our admin-php.
>
> Looking through the code of opensipsctl it seems to make an SQL query
> inserting the new user straight into the Databse without passing FIFO or
> such.
>
>
>
> Does there exist a more “modern” way of doing this or is this the procedure
> used nowadays?
>
>
>
> BTW, Anyone interested in the final PHP code of triggering a reboot of
> Linksys and Grandstream using XML-RPC, just let me know. Actually also some
> code of reboot of Siemens devices, although not through opensips.
>
>
>
> Best Regards,
>
> Matti Zemack, Stockholm, Sweden
>
>
>
>
>
>
>
>
>
> *RTC Factory AB*
>
> Jungfrugatan 6
>
> 114 44 Stockholm
>
> SWEDEN
>
>
>
> Tel: +46-8 410 420 03
>
> SMS: +46-709 625 173
>
> Fax: +46-8 410 420 49
>
> Email: [email protected]
>
>
>
>
>
> *RTC Factory is a global communications provider, targeting virtual
> operators and ISPs. RTC Factory provides “Communication as a Service”:
> basically the equivalent of Google’s GrandCentral combined with Skype and
> Rebtel functionality. These IP-based services are hosted and provided within
> a white-label framework, and sold through the provider’s regular sales
> channels.*
>
>
>
> _______________________________________________
> Users mailing list
> [email protected]
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>
>
_______________________________________________
Users mailing list
[email protected]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users