How to deploy Rocket.Chat on AWS – Part I

Rocket.Chat on Debian 9

Introduction to Rocket.Chat

We have already talked about Rocket.Chat, a private messaging system like Slack and Mattermost, and how to install and configure it on a “local” server.
However, many infrastructures are based on Amazon Web Services, which offers a suite of cloud computing services. In particular the Amazon Elastic Compute Cloud, or Amazon EC2.
This series of tutorials explain how to deploy Rocket.Chat on Amazon Web Services (AWS), using Ubuntu 14.04 LTS as AMI.

Getting started

In AWS Services, go to EC2 > Instances > Launch Instance. There, select Ubuntu Server 14.04 LTS AMI.
For Instance Type, choose t2.micro. The T2 instances are useful, in particular, for websites and web applications, build servers, micro services, or test and staging environments.
Screenshot_20170311_132200
For Rocket.Chat, t2.micro seems a good choice.
Next, adjust the storage size, or add a second encrypted volume, and click on Next. In ‘Tag Instance’ add a Value to the Name Key and go on.
Next, it’s necessary to configure a security group. Right now, be sure to allow traffic to the server on port 80 until the SSL certificate is created. After that step, it’s possible to remove the group. Click on Launch, then create a new key pairs and launch a new instance.

Allocate an IP

In AWS Services, go to EC2 and the to ElasticIP. Here, allocate a new address and associate the instance launched in the previous steps.
In the details, it’s important to take note of the Public DNS value, because it will be needed later. This should be in the format ec2-00-111-22-33.us-west-2.compute.amazonaws.com.

Configure DNS using AWS Route 53

In AWS Services, you should always go to Route 53. Amazon Route 53 is a highly available and scalable cloud DNS web service, designed to provide a reliable and cost effective way to route end users to Internet applications. It is IPv6 compliant.
Using Amazon Route 53 Traffic Flow’s visual editor, it’s possible to manage how end-users are routed to application’s endpoints, whether in a single region or distributed. Amazon Route 53 also offers a domain name registration service.
Create a new Hosted Zone, entering a domain name and choosing Public Hosted Zone. Click on Create.
After selecting this new zone, create a record set and select as type CNAME. Then, enter the Public DNS name from the previous step to the value field and click on Create.

Get a SSL certificate

In 2017 it’s necessary to use HTTPS connections, and Chrome is still signalling services which don’t allow it. So, it’s important to get an SSL certificate.
For this task we will use Let’s Encrypt.
On the instance, clone the letsencrypt repository:

# git clone https://github.com/letsencrypt/letsencrypt /opt/letsencrypt

Next, check on port 80:

# netstat -na | grep ':80.*LISTEN'

If any processes are listening, kill them all.
Next, to get the certificate, go to /opt/letsencrypt and run the standalone plugin, with the following commands:

# cd /opt/letsencrypt
# ./letsencrypt-auto certonly --standalone --email "email_address_here" -d "mydomain.com"

During this passage, letsencrypt will listen on port 80.
When this is finished, it’s possible to remove the previously created security group.
Now, it’s possible to check for certificate and keys. In particular, directory /etc/letsencrypt/archive should contain the following files:

  • cert.pem
  • chain.pem
  • fullchain.pem
  • privkey.pem

fullchain.pem is the admin’s certificate file, while privkey.pem is his certificate key file.

Conclusions

With the previous steps, the first half of the journey is complete. It’s important to execute all steps carefully, because this is the basis on which Rocket.Chat will be deployed on an AWS Instance.

  • I have been on lots of systems but nothing at all worked well for me in a proper manner. At last in 2012 I discovered a system which is crazy. It is quite simple and easy to setup and I started advertising it within few mins.This system works and is ideal for everybody regardless of age group,educational background or professional skills.You can get instant results even if you feel like you have sup-par computer skills.I have earned $1000 within my first 7 days after which I am getting $10000 or even more each month.Thank you for creating this amazing system that is perfect for the average person >>>> http://deliciousurl­.­com//35

  • Being profitable via internet is really as effortless (or sometimes as hard) such as getting you a good return offline. Even though a huge number of Making money over the internet consultants guarantee to surely have a hidden knowledge solution making immediate bucks, the truth is, it does not use any strategy you actually can grow wealthy person over-night by simply clicking on a key or just shopping numerous e book. Generating revenue on the net really needs working hard and persistence. If you find yourself capable of give plenty of time and energy involved, there are several options for earning extra cash through the internet.I am gaining 10 thousand dollars or even just more month to month out of this task.Here’s the quick way to make cash even though the rest are long-term ideas to make money >>>>> OUOURL.COM/4rfh

  • Ever cashed in plenty of cash without trading in a thing and even left out doing any of the multi-level marketing sort of work and one never has to make an investment anything at all. Allow me to talk about a work wherein almost all software is generally handovered to you and consequently it really is a relatively easy and effortless job. Not necessary to build your websites and many more., almost all is going to be provided to you without any expense. People should certainly browse through your web blog and you are certain to get money for that. Its as simple as that. Now I am earning a ton of cash from home from this task just like 20000 dollars per thirty days and more if you too would like to earn like this then follow here trouble-free guidelines by going to this web page >>>>> URL4.UK/rk0aG

  • fgcghkbvhjbhjbhjbhjbnjk

  • FreeƖanсe ſrοm hoʍe fᴦom two-sɪх hoυrƽ ev℮ᴦy day, ɑոᏧ ƽτaгτ eaᴦոͺᴨց fr೦м ೦ոe to ᴛhг℮e thouƽaϖd bucкs ɑt tһ℮ eոd of every ᴡeeĸ܂ Reαd more inf੦rmaτiσn һeᴦе˃ V15.UK/YXoTp

  • I w౦uןd liĸe t໐ ƽhow yoц a fantɑstιc wαy үoᴜ ϲaϖ geτ ϱaid ƽ೦me incoмe eveᴦy week by ɯorкᎥng Ꮟasic taƽks οveг ѡeᖯ ſrom үouᴦ lіᴠіng ᴦo๐m foг sevеᴦal հᴦƽ ɑ 〳ԁαy ~  Ϲliᴄk oᴨ the w℮ЬƽᎥte GET.LC/5QJ7L

    dfghfhgj

  • I initiated freelancing over world wide web, through doing some basic tasks which primarily demanded a computer and consequently access to net and additionally Now I am satisfied than ever before… six months time get gone by since i started out this and therefore i received cash total of $36,000… Basically I make eighty usd each hour and even work for 3 to four hrs most of the days.And beauty of this is that you can organize time whenever you work and so for how long as you like but you still gain a paycheck weekly. —->>>LEARN A lot more About That here-> V15.UK/96i5Z

    gdfg

  • I started out freelancing over internet, through doing some fundamental work which solely required your working personal computer and consequently usage of internet and Now I am delighted than always… 6 months have passed by when i started out this and additionally i had profit total of 36 thousand dollars… Basically I earn 80 bucks each and every hour as well as work for 3 to four hours most of the times.And beauty of this is that you can manage precious time when you work and so for how long as you like but you still get a take-home pay in one week. —->>>LEARN Additional Regarding It here-> RU.VU/bzJLB

    dfsgddgs

  • I tried freelancing over world-wide-web, via doing some fundamental opportunities which just simply requisite your personal computer and also usage of internet and additionally Now I am delighted than ever… half a year have passed when i started this and i received money full amount of of 36,000 dollars… Basically I make 80 bucks each and every hour and also work for 3 to 4 hrs majority of the times.And attractiveness of this is exactly that you can organize time whenever you work and for how long as you like and you earn a paycheck each week. —->>>LEARN Even more Regarding It here-> GOCHIURL.COM/15cf7

    dfsdfsdf