LesPerras.com

Summer is Here. Ghost in a Subdomain

I can’t believe summer is here already. Well technically it is not summer yet. We are still in the rainy season. But not for long. The temperature is regularly going over 30°C here now. And the humidity is high.

I just installed ghost as the blogging platform for my site. It was actually quite easy.

The hardest part was setting up the subdomain. I finally figured out how to set up the subdomain! I set the DNS settings over at route53 so there was a new subdomain with an A record, pointing to this ip address.

Then I set up a new file in nginx sites-available with this code:

server{ listen 80; server_name yourservernamehere; location / { proxy_set_header X-Real-IP $remote_addr; proxy_set_header Host $http_host; proxy_pass http://127.0.0.1:xxxx; }}

and that was it. The last line for proxy_pass is for ghost, since it runs on nodejs. You have to replace xxxx with the port you are running that instance of node on.

Pretty easy, huh? Just took me a bit of searching and testing. Actually, this is my third round trying, and it took me about an hour to set it up. Now, having done it, I probably could do it as www.lesperras.com/blog, but I am happy with blog.lesperras.com in a sense it looks cooler.

I am pretty happy with ghost. very simple to use. And lightning fast.

No picture on this blog entry. Not yet, anyway.