Upload
elastix
View
583
Download
3
Embed Size (px)
DESCRIPTION
"Real" integración de una Cámara IP a Elastix Alfredo Zambrano Gerente Comercial PaloSanto Solutions
Citation preview
ESQUEMA
CONFIGURACIONES
Configuraciones de Correo.
Configuraciones de Elastix.
Configuraciones de Cámara IP.
CONFIGURACIONES DE CORREOPaso 1: Editar el archivo main.cf agregar al final la linea virtual_alias_maps =hash:/etc/postfix/virtual
CONFIGURACIONES DE CORREO
Paso 2: En el mismo archivo agregar la linea: alias_maps = hash:/etc/postfix/aliases
CONFIGURACIONES DE CORREOPaso 3: En el archivo virtual: [email protected] webinar [email protected]
CONFIGURACIONES DE CORREO
Paso 4: En el archivo aliases: webinar: "|/usr/bin/php /usr/local/bin/email2call-200;
CONFIGURACIONES DE CORREOPaso 5: Ejecutar los comandos postalias aliases; postmap virtual; service postfix reload
CONFIGURACIONES DE CORREO
Paso 6: Crear el dominio “elastix.lan” y la cuenta webinar en el módulo Email de Elastix.
CONFIGURACIONES ELASTIXPaso 7: En el archivo manager_custom.conf crear el usuario “email2call” y luego ejecutar:
asterisk -rx “manager reload”.
CONFIGURACIONES ELASTIXPaso 8: Crear el script “email2call-200” en /usr/local/bin. Luego, cambiarle los permisos a
777 y el propietario a asterisk
CONFIGURACIONES ELASTIX
Paso 9: En el archivo extensions_custom, agregar el contexto: mensaje_seguridad. Luego,ejecutar el comando: asterisk -rx “reload”
CONFIGURACIONES ELASTIX
Paso 10: Crear las extensión 200 desde el módulo PBX de Elastix.
CONFIGURACIONES DE LA CÁMARA IP
Paso 11: Configurar el Mail Server y las cuentas de correo a donde será enviada las imágenes.
CONFIGURACIONES DE LA CÁMARA IP
Paso 12: Activar Detección de Movimiento en la cámara IP
AHORA VEAMOS COMO FUNCIONA !!
Script – email2call-200
<?php$strHost = "127.0.0.1";$strUser = "email2call";$strSecret = "Palosanto";$strContext = "from‐internal";$strWaitTime = 45;$strPriority = 1;$strMaxRetry = "1";$number="8765";$strChannel = "SIP/200";if ($strChannel!="" ) :
$errno=0 ;$errstr=0 ;$strCallerId = " FOSCAM ";$oSocket = fsockopen ($strHost, 5038, $errno,
$errstr, 20);if (!$oSocket) {
echo "$errstr ($errno)<br>\n";} else {
fputs($oSocket, "Action: login\r\n");fputs($oSocket, "Events: off\r\n");fputs($oSocket, "Username: $strUser\r\n");fputs($oSocket, "Secret:
Script – email2call-200
$strSecret\r\n\r\n");fputs($oSocket, "Action: originate\r\n");fputs($oSocket, "Channel:
$strChannel\r\n");fputs($oSocket, "WaitTime:
$strWaitTime\r\n");fputs($oSocket, "CallerId:
$strCallerId\r\n");fputs($oSocket, "Exten: $number\r\n");fputs($oSocket, "Context:
$strContext\r\n");fputs($oSocket, "Priority:
$strPriority\r\n\r\n");fputs($oSocket, "Action: Logoff\r\n\r\n");sleep(2);fclose($oSocket);
}if (!isset($_REQUEST['exten'])){
echo "";} else {
echo "$strChannel enlazando a $number." ;}
else :exit() ;
endif ;?>
Script – email2call-201
<?php$strHost = "127.0.0.1";$strUser = "email2call";$strSecret = "Palosanto";$strContext = "from‐internal";$strWaitTime = 45;$strPriority = 1;$strMaxRetry = "1";$number="8765";$strChannel = "SIP/201";if ($strChannel!="" ) :
$errno=0 ;$errstr=0 ;$strCallerId = " FOSCAM ";$oSocket = fsockopen ($strHost, 5038, $errno,
$errstr, 20);if (!$oSocket) {
echo "$errstr ($errno)<br>\n";} else {
fputs($oSocket, "Action: login\r\n");fputs($oSocket, "Events: off\r\n");fputs($oSocket, "Username: $strUser\r\n");fputs($oSocket, "Secret:
$strSecret\r\n\r\n");fputs($oSocket, "Action: originate\r\n");
Script – email2call-201
fputs($oSocket, "Channel: $strChannel\r\n");
fputs($oSocket, "WaitTime: $strWaitTime\r\n");
fputs($oSocket, "CallerId: $strCallerId\r\n");
fputs($oSocket, "Exten: $number\r\n");fputs($oSocket, "Context:
$strContext\r\n");fputs($oSocket, "Priority:
$strPriority\r\n\r\n");fputs($oSocket, "Action: Logoff\r\n\r\n");sleep(2);fclose($oSocket);
}if (!isset($_REQUEST['exten'])){
echo "";} else {
echo "$strChannel enlazando a $number." ;}
else :exit() ;
endif ;?>
GRACIAS !
PREGUNTAS ?