title: EC2 SSL not working
body: <p>I'm running an EC2 micro instance (Amazon Linux) and can't seem to get ssl (https) working.</p>
  
  <p>The error I'm getting in Chrome is "ERR_CONNECTION_REFUSED" (no data sent).</p>
  
  <p>I've enabled HTTPS inbound traffic for the security group in my AWS console.</p>
  
  <p>I added this in the /etc/httpd/conf/httpd.conf file. (example.com is a placeholder for my website)</p>
  
  <pre><code>&lt;VirtualHost *:80&gt;
      ServerName example.com
      Redirect permanent / https://example.com/
  &lt;/VirtualHost&gt;
  
  &lt;VirtualHost *:443&gt;
      ServerName example.com
      SSLEngine on
      SSLCertificateFile /etc/ssl/example_com.crt
      SSLCertificateKeyFile /etc/ssl/example_com.key
      SSLCertificateChainFile /etc/ssl/example_com.ca-bundle
  &lt;/VirtualHost&gt;
  </code></pre>
  
  <p>and it didn't work.</p>
  
  <p>So to test VirtualHost, I replaced it with the following:</p>
  
  <pre><code>&lt;VirtualHost *:80&gt;
      ServerName example.com
      Redirect permanent / https://google.com/
  &lt;/VirtualHost&gt;
  
  &lt;VirtualHost *:443&gt;
      ServerName example.com
      Redirect permanent / https://google.com/
  &lt;/VirtualHost&gt;
  </code></pre>
  
  <p><a href="http://example.com" rel="nofollow">http://example.com</a> redirected to google like expected, but <a href="https://example.com" rel="nofollow">https://example.com</a> didn't.</p>
  
  <p>Anyone know what's the problem?</p>