Introducing 

Prezi AI.

Your new presentation assistant.

Refine, enhance, and tailor your content, source relevant images, and edit visuals quicker than ever before.

Loading…
Transcript

【/etc/asterisk/sip.conf】

1: [general]

2: port=5060

3: disallow=all

4: allow=gsm

5: localnet=192.168.0.0/255.255.0.0

6: externip={global ip address}

7:

8: [201]

9: type=friend

10: defaultuser=201

11: secret=pass

12: canreinvite=no

13: host=dynamic

14: dtmfmode=rfc2833

15: callgroup=1

16: pickupgroup=1

17: mailbox=201

【/etc/asterisk/extensions.conf】

1: [default]

2: exten => 316,1,Goto(at,1)

3: exten => at,1,Wait(3)

4: exten => at,2,Answer()

5: exten => at,3,AGI(example.php)

【/var/lib/asterisk/agi-bin/aws/config.inc.php】

50: CFCredentials::set(array(

51:

52: // Credentials for the development environment.

53: 'development' => array(

54:

55: // Amazon Web Services Key. Found in the AWS Security Credentials. You can also pass

56: // this value as the first parameter to a service constructor.

57: 'key' => 'development-key',

58:

59: // Amazon Web Services Secret Key. Found in the AWS Security Credentials. You can also

60: // pass this value as the second parameter to a service constructor.

61: 'secret' => 'development-secret',

ご挨拶

千葉 哲也

株式会社サーバーワークス(2011/09〜)

twitter:@kachina_t

今後の妄想

http://blog.serverworks.co.jp/tech/

アメリカアラバマ州のデジウム社が開発している

オープンソースのIP-PBXのソフトウェア。

GPL2ライセンスで配布。

ネーミングはアスタリスクマーク(*)に由来する。

[3. ファイルリスト]

[2. インストール]

[4. 設定ファイルの編集]

1: # yum install -y libxml2-devel gcc gcc-c++ make subversion ncurses-devel php

2: # cd /usr/local/src

3: # svn export http://svn.digium.com/svn/asterisk/tags/1.8.9.1 ./asterisk

4: # cd ./asterisk

5: # ./configure

6: # make install

7: # make samples

8: # svn export --force https://phpagi.svn.sourceforge.net/svnroot/phpagi/tags/REL-2.14/ /var/lib/asterisk/agi-bin/

9: # cd /usr/local/src

10: # wget http://pear.amazonwebservices.com/get/sdk-latest.zip

11: # unzip sdk-latest.zip

12: # cp -R sdk-1.5.2/sdk-1.5.2 /var/lib/asterisk/agi-bin/aws

13: # cp /var/lib/asterisk/agi-bin/aws/config-sample.inc.php /var/lib/asterisk/agi-bin/aws/config.inc.php

[1. インスタンスの起動]

Security Group

UDP:5060

[5. SIPクライアントのセットアップ]

price

1. インスタンスの起動

2. インストール

3. ファイルリスト

4. 設定ファイルの編集

5. SIPクライアントのセットアップ

6. IVRスクリプトの作成

7. Asteriskの起動

8. 通話

9. ・・・・・・・・・・

0. ・・・・・・・・・・

[6. IVRスクリプトの作成]

1: #!/usr/bin/php

2: <?php

3: require_once('phpagi.php');

4: require_once('aws/sdk.class.php');

5:

6: $agi = new AGI();

7: $agi->answer();

8:

9: $sdb = new AmazonSDB();

10: $domain = 'logs';

11: $sdb->create_domain($domain);

12:

13: while (true) {

14: $dtmf = $agi->get_data('hello-world', 5000, 3);

15:

16: if (!$dtmf['result']) {

17: break;

18: }

19:

20: foreach (str_split($dtmf['result']) as $value) {

21: $agi->say_number($value);

22: $agi->exec('wait', 0.25);

23: }

24:

25: $item = date('c');

26: $attributes = array(

27: 'caller' => $agi->request['agi_callerid']

28: , 'value' => $dtmf['result']

29: );

30: $sdb->put_attributes($domain, $item, $attributes);

31: }

32:

33: $agi->stream_file('vm-goodbye');

34: $agi->exec('busy');

package

¥575,000

saas

¥262,900/月

[7. Asteriskの起動]

# asterisk -vvvvvvvvc

call:316

今日のお題

【Interactive Voice Response】の略

音声による自動応答を行うコンピュータシステム。

発信者のダイヤル操作に合わせて、あらかじめ録音して

ある音声を発信者側に自動的に再生(ry

AWSとAsteriskを駆使して

安くて・早くて・うまい

IVRシステムを作ってみる

EC2 on Asterisk-IVR

Learn more about creating dynamic, engaging presentations with Prezi