際際滷

際際滷Share a Scribd company logo
34 AVENUE DE LOPRA > 75002 PARIS > FRANCE > WWW.OCTO.COM
MEETUP ALEXA  18 JUNE 2017
HOUSTON
Or how I tell my applications to go deploy themselves
FIRST THINGS FIRST
造 Eric FAVRE
> Software engineer at OCTO
Technology
> @e_favre
> efavre@octo.com
造 OCTO Technology
> IT Consulting company
> Sydney, Paris, Rabat, Lausanne and
Sao Paulo
> @OCTODownUnder
OCTO TECHNOLOGY > THERE IS A BETTER WAY 2
01 CONCEPT
ALEXA SOUNDS LIKE FUN, WHAT COULD WE DO WITH IT?
造 Coding night about Alexa @ Octo
> Many ideas raised during brainstorming session
> What about triggering deployments by voice?
造 Secure Alexa skills
> Funny mishap about a girl ordering a dollhouse with Alexa triggering more unwanted
orders from other households when the story makes the news on TV
> Alexa does provide a code protection for purchases only
> How to make sure the person requesting Alexa is actually in the same room as
Alexa?
> Some kind of 2 Factor Authentication, only not bound to someone, but to
somewhere
2 ideas merged into one
OCTO TECHNOLOGY > THERE IS A BETTER WAY 4
HERE COMES HOUSTON
造 束 Alexa, deploy Rocket to Production using Houston 損
造 束 Alexa, confirm operation kangaroo using Houston 損
Collocated LCD screen for operation confirmation
OCTO TECHNOLOGY > THERE IS A BETTER WAY 5
HERE COMES HOUSTON
Minimalist design
OCTO TECHNOLOGY > THERE IS A BETTER WAY 6
02 LETS GET TECHNICAL
ARCHITECTURE
OCTO TECHNOLOGY > THERE IS A BETTER WAY 8
Voice capture
Voice processing Houston logic
Jenkins
LCD REST API
ARCHITECTURE
OCTO TECHNOLOGY > THERE IS A BETTER WAY 9
Voice capture
Voice processing Houston logic
Jenkins
LCD REST API
dataplicity
AWS Lambda
AWS EC2
Raspberry Pi
AWS Alexa Skills Service
Echo Dot
AWS DynamoDB
LCD Screen
ALEXA SKILL
造 Intent Deploy
> Slots:
+ Application
+ Environment
> Utterances:
+ Deploy {application} to {environment}
+ Push {application} to {environment}
+ Send {application} to {environment}
造 Intent Confirm
> Slots:
+ Code
> Utterances
+ Confirm with code {code}
+ Confirm with {code}
+ Confirm operation {code}
+ 
OCTO TECHNOLOGY > THERE IS A BETTER WAY 10
HOUSTON BUSINESS LOGIC
造 Method requestDeployment(application,
environment)
> Check application and environment
belong to known sets
> Pick random code word out of list
> Store into DynamoDB
+ code:{environment,application}
> Call LCD REST API with message
Deploy code: code
造 Method confirmDeployment(code)
> Retrieve value matching key code from
DynamoDB
> Call Jenkins API with job variables
application and environment
OCTO TECHNOLOGY > THERE IS A BETTER WAY 11
LCD REST API
造 curl	-d	'{"text":"Deploy	code:	code}'	
https://myapi.dataplicity.io/messages/		
-H	"Content-Type:	application/json"	
造 Node.js
> Simple REST API on an express.js server
造 Python script
> Configure LCD screen and write text using
Adafruit_CharLCD library
OCTO TECHNOLOGY > THERE IS A BETTER WAY 12
03 DEMONSTRATION
THANK YOU!
@e_favre
@OCTODownUnder
https://github.com/octo-technology-downunder/houston

More Related Content

Houston

  • 1. 34 AVENUE DE LOPRA > 75002 PARIS > FRANCE > WWW.OCTO.COM MEETUP ALEXA 18 JUNE 2017 HOUSTON Or how I tell my applications to go deploy themselves
  • 2. FIRST THINGS FIRST 造 Eric FAVRE > Software engineer at OCTO Technology > @e_favre > efavre@octo.com 造 OCTO Technology > IT Consulting company > Sydney, Paris, Rabat, Lausanne and Sao Paulo > @OCTODownUnder OCTO TECHNOLOGY > THERE IS A BETTER WAY 2
  • 4. ALEXA SOUNDS LIKE FUN, WHAT COULD WE DO WITH IT? 造 Coding night about Alexa @ Octo > Many ideas raised during brainstorming session > What about triggering deployments by voice? 造 Secure Alexa skills > Funny mishap about a girl ordering a dollhouse with Alexa triggering more unwanted orders from other households when the story makes the news on TV > Alexa does provide a code protection for purchases only > How to make sure the person requesting Alexa is actually in the same room as Alexa? > Some kind of 2 Factor Authentication, only not bound to someone, but to somewhere 2 ideas merged into one OCTO TECHNOLOGY > THERE IS A BETTER WAY 4
  • 5. HERE COMES HOUSTON 造 束 Alexa, deploy Rocket to Production using Houston 損 造 束 Alexa, confirm operation kangaroo using Houston 損 Collocated LCD screen for operation confirmation OCTO TECHNOLOGY > THERE IS A BETTER WAY 5
  • 6. HERE COMES HOUSTON Minimalist design OCTO TECHNOLOGY > THERE IS A BETTER WAY 6
  • 7. 02 LETS GET TECHNICAL
  • 8. ARCHITECTURE OCTO TECHNOLOGY > THERE IS A BETTER WAY 8 Voice capture Voice processing Houston logic Jenkins LCD REST API
  • 9. ARCHITECTURE OCTO TECHNOLOGY > THERE IS A BETTER WAY 9 Voice capture Voice processing Houston logic Jenkins LCD REST API dataplicity AWS Lambda AWS EC2 Raspberry Pi AWS Alexa Skills Service Echo Dot AWS DynamoDB LCD Screen
  • 10. ALEXA SKILL 造 Intent Deploy > Slots: + Application + Environment > Utterances: + Deploy {application} to {environment} + Push {application} to {environment} + Send {application} to {environment} 造 Intent Confirm > Slots: + Code > Utterances + Confirm with code {code} + Confirm with {code} + Confirm operation {code} + OCTO TECHNOLOGY > THERE IS A BETTER WAY 10
  • 11. HOUSTON BUSINESS LOGIC 造 Method requestDeployment(application, environment) > Check application and environment belong to known sets > Pick random code word out of list > Store into DynamoDB + code:{environment,application} > Call LCD REST API with message Deploy code: code 造 Method confirmDeployment(code) > Retrieve value matching key code from DynamoDB > Call Jenkins API with job variables application and environment OCTO TECHNOLOGY > THERE IS A BETTER WAY 11
  • 12. LCD REST API 造 curl -d '{"text":"Deploy code: code}' https://myapi.dataplicity.io/messages/ -H "Content-Type: application/json" 造 Node.js > Simple REST API on an express.js server 造 Python script > Configure LCD screen and write text using Adafruit_CharLCD library OCTO TECHNOLOGY > THERE IS A BETTER WAY 12