Setting up the Coral Project’s Talk product on AWS

This morning I spent some time kicking the tires on Coral Project’s Talk. Comments that don’t suck! If you’ve already got Ask running, you’ve got a headstart in AWS – just replicate the setup. Come back when you’ve got that done.

One issue I ran into at this point: The EC2 cluster hostname ended up in the Ubuntu sources file. Some more info in this thread. After I got that cleared up and updated apt, I installed docker.

Before we get the app running, we’ve got to get Redis and MongoDB started. I decided to use the official Docker containers and run them in the background.

docker run --name talk-redis -d redis && docker run --name talk-mongo -d mongo

Add your Ubuntu user to the docker group, restart the session with a reboot or logout/login, and then you can use the docker command in the Talk install readme. Playing around with that command for a bit, I settled on this as my startup command. I tried to go with an empty plugins object at first, but ran into some issues with the GraphQL responses, so that’s why I have the Facebook app ID/secret included too.

docker run --rm -p 5000:5000 \
-e TALK_MONGO_URL=mongodb://mongo/talk \
-e TALK_REDIS_URL=redis://redis \
-e TALK_FACEBOOK_APP_ID=5554432162346234 \
--link talk-redis:redis \
--link talk-mongo:mongo \

The --rm means that the container gets destroyed after it runs. I’m also not using the -D detached command so I see the Node feedback.

Due to the embed nature of Talk, SSL is highly recommended. Caddy handles all the SSL setup quite easily, here’s what my Caddy file looks like. The -p 5000:5000 above takes the port 5000 out of Docker container and makes it available in the server.
proxy / localhost:5000

Now, in a separate tab connected to my instance, I got the Talk docker container ID using docker ps and then ran docker exec -it {{container ID}} cli setup to launch myself into the interactive setup process.

After that, I was able to login at the /admin/configure address.

So now you might want to change the process for docker run to not include the TALK_INSTALL_LOCK flag. I haven’t setup email or recaptcha yet, and the code above can probably be improved to make this run as a background with auto-restart. But that’s enough for now! Let me know what you think in the comments :).

Posted May. 17 2017, 10:34 am by Davis