However, after logging into the ec2 server using SSH, I can’t find the file /etc/nginx/sites-available/redash mentioned in the instructions because the folder /etc/nginx doesn’t exist.
I’m not familiar with nginx so I have no idea where to look for it.
(My intention is to use AWS CloudFront in front of the Redash server, in order to use HTTPS, like mentioned here )
If you put Redash behind an ELB or Cloudfront, then you don’t need to apply any changes except for updating the number of proxies configuration.
If you want Redash’s server to serve HTTPS traffic, then you need to follow this guide:
The one in the Knowledge Base is for the legacy AMIs we were distributing… I added a note about this to this page, to avoid future confusion. And eventually we will publish the gist as part of the Knowledge Base.
I successfully set up a Cloudfront distribution to use HTTPS on my Redash server.
Here is a quick guide if anyone else is trying to do that:
Create a HTTPS certificate with AWS Certificate Manager for your redash server domain name (ex: redash. yourdomain. com) and validate it
Go to CloudFront, create a web distribution with the following configuration:
a) At “Alternate Domain Names (CNAMEs)” enter your custom domain (ex: redash.yourdomain.com)
b) Select Custom SSL Certificate and choose the certificate created at the previous step
c) At “Origin Domain Name” enter the “Public DNS” of your EC2 server (something like ec2-XXXXXXX. amazonaws. com where your redash server is located)
d) At Behaviors, set “Viewer Protocol Policy” to “Redirect HTTP to HTTPS”
e) At “Allowed HTTP Methods” choose “GET, HEAD, OPTIONS, PUT, POST, PATCH, DELETE”
f) At “Cache Based on Selected Request Headers” and “Forward Cookies” choose All
g) At “Query String Forwarding and Caching” choose “Forward all, cache based on all”
Wait for your CloudFront distribution to show up as Deployed. You can check it by going to its address (something like xxxxxx. cloudfront. net)
At Route53, point your custom domain to the Cloudfront distribution, using A, selecting Alias=yes, and choosing your CloudFront distribution