Upgrade to Pro — share decks privately, control downloads, hide ads and more …

AWS x Alexa対策講座

chao2suke
August 21, 2018

AWS x Alexa対策講座

2018/08/21 Alexa Salon SP@東京 資料

chao2suke

August 21, 2018
Tweet

More Decks by chao2suke

Other Decks in Technology

Transcript

  1. Agenda ✦ جຊͱͯ͠ԡ͓͑ͯ͘͞αʔϏε ✦ AWS IAM ✦ DynamoDB ✦ Cognito

    ✦ AlexaͷදݱྗΛิ͏ ✦ AWS IoT ✦ Kinesis Video Stream + Rekognition Video ✦ ӡ༻Λॿ͚Δ ✦ CloudWatch Logs ✦ API Gateway 3
  2. 5 AWS IAM ✦ ֤AWS αʔϏεͷ࢖༻ݖݶΛ੍ޚ͢Δ ✦ ʮϢʔβʔʯ͕αʔϏεΛ࢖͑Δ
 => IAM

    User ✦ ʮαʔϏεΛ࢖͑ΔݖݶʯΛ
 ͍Ζ͍Ζͳ΋ͷʹ͚ͭΔ => IAM Role ✦ LambdaͷτϦΨʔ͔Β֬ೝͰ͖Δ
  3. 16 DynamoDB ηΧϯμϦΠϯσοΫε Hash Key Range Key Hash Key Local

    Secondary Index Range Key Global Secondary Index
  4. 25 Cognito ✦ AWSͷೝূαʔϏε ✦ Facebook / Google / Amazon

    Login / Twitter౳ʹରԠ ✦ ಠࣗͷೝূج൫ʮCognito User Poolʯ Λ࡞੒Ͱ͖Δ
 =>AlexaʹखܰͳೝূΛ͚ͭΒΕΔ
  5. 26 Cognito Device ID ✦ Device ID͸εΩϧͷOFF/ONͰมΘΔ ✦ εΩϧ͸Ի੠ͰOFF/ON͕Ͱ͖Δ ✦

    Alexa͸݁ߏޡೝࣝ͢Δ ✦ ஌Βͳ͍ؒʹ͢΂ͯͷDeviceID͕มΘ͍ͬͯΔ ͜ͱ͕͋Δ
  6. Agenda ✦ جຊͱͯ͠ԡ͓͑ͯ͘͞αʔϏε ✦ AWS IAM ✦ DynamoDB ✦ Cognito

    ✦ AlexaͷදݱྗΛิ͏ ✦ AWS IoT ✦ Kinesis Video Stream + Rekognition Video ✦ ӡ༻Λॿ͚Δ ✦ CloudWatch Logs ✦ API Gateway 28
  7. 31 AWS IoT ✦ Echo Spot΍εϚϗ্ͷΧʔυ͸ܾΊΒΕͨς ϯϓϨʔτʹը૾΍ө૾ΛࡌͤΔܗࣜ ✦ Web SocketʹࡌͤΔ͜ͱͰϒϥ΢β্ͱAlexa

    ΛϦΞϧλΠϜ௨৴ͤ͞Δࣄ͕Ͱ͖Δ ✦ IoT SDKΛࡌͤΒΕΔͳΒεϚϗΞϓϦͱ௨৴ ͯ͠ө૾ΛมԽͤ͞Δ͜ͱ΋
  8. 34 Kinesis Video Stream + Rekognition Video ✦ ಈըετϦʔϜαʔϏε &

    ෼ੳαʔϏε ✦ AWSʹ҆શʹಈըΛετϦʔϜ͠ɺϦΞϧλΠ Ϝɺόονॲཧ྆ํʹରԠ͢Δ ✦ ಈըΛ෼ੳ͠ɺإೝࣝɺإೝূͳͲͷ෼ੳ࡞ۀ ͕ߦ͑Δ ✦ ྆αʔϏε͸σϑΥϧτͰ࿈ܞͰ͖Δ
  9. 35 Kinesis Video Stream + Rekognition Video ✦ Echoʹ͸Χϝϥ͕ͳ͍ͨΊɺϊϯόʔόϧί ϛϡχέʔγϣϯ͕શ͘Ͱ͖ͳ͍

    ✦ ΧϝϥΛ࢖༻ͯ͠ඇಉظʹ࿈ܞͤ͞Δ͜ͱͰ΍ ΓͱΓʹΑΓਓؒຯΛ΋ͨͤͨΓɺ༨ܭͳ΍Γ औΓΛলུͨ͠ΓͰ͖Δ ✦ Camera recap APIͱ͍͏ͷ΋ग़͖͍ͯͯΔ Alexa
  10. 36 Kinesis Video Stream + Rekognition Video K i n

    e s i s V i d e o S t r e a m R e k o g n i t i o n V i d e o K i n e s i s D a t a S t r e a m S t r e a m P r o c e s s o r
  11. Agenda ✦ جຊͱͯ͠ԡ͓͑ͯ͘͞αʔϏε ✦ AWS IAM ✦ DynamoDB ✦ Cognito

    ✦ AlexaͷදݱྗΛิ͏ ✦ AWS IoT ✦ Kinesis Video Stream + Rekognition Video ✦ ӡ༻Λॿ͚Δ ✦ CloudWatch Logs ✦ API Gateway 37
  12. 39 CloudWatch Logs ✦ AWSͷϩάαʔϏε ✦ ࠷େ10೥·Ͱͷϩάอ؅͕Մೳ ✦ ϑΟϧλΛ͔͚ͯɺಛఆͷϩάΛநग़Ͱ͖Δ ✦

    αϒεΫϦϓγϣϯϑΟϧλͰɺநग़ ͨ͠ϩάʹϦΞϧλΠϜͰॲཧΛૹΔ͜ͱ͕Ͱ ͖Δ