Tell HN: I built a $5/mo JavaScript-free Rails app

22 points by victroladixit ↗ HN
I'm happy about an app I've been working on for over a year. I'm still wrangling with the 'cookies.js' file placed on the client, with a session id, otherwise it's free of any javascript. I hadn't used Redis in the past, had been content with sub-second page loads. Now I'm getting unbelievable (to me) results under 50ms for most pages, except 3rd party API calls for coin prices and service rates.

I'm getting my head around the content security policy, extracting the google fonts into my apps domain, not using analytics.

It's only running on 1cpu/1gb/1appserver, which I've pared down from 4cpu/4gb/2appserver. So it's $5/mo for the VPS. I may have some knowlege to share, if you're interested.

https://coinship.pro

14 comments

[ 2.6 ms ] story [ 40.7 ms ] thread
What is it about?
Buying shipping labels with cryptocurrencies
Is the use case what I think it is? By which I mean very legal and very cool activities?
I wonder why they would want to be Javascript-free :)
I actually have no idea what the use case could be for it. Enlighten me?
If you are asking him what use case he is describing there, it's dark net markets. Buying and selling of drugs and other items via TOR using crypto currency.
The app is down right now. I'm getting 502 errors
> The app is down right now. I'm getting 502 errors

Seems to be up right now, but CSS was acting up a bit until a few moments ago.

Page loads are consistently over 1.5s though, with the HTML taking approx 1s. Not something to write home about.

I had to recompile assets and the site was running at up to 20rpm, and it stalled. Back online now. The navbar prices are updated every 3 minutes, which takes 2s, and caches are 50ms until the update. I want to put the updates in a background job, but it isn't crucial yet.
even after optimizing your rails app, you still need to send HTML to your users through the interwebs.

you can optimize this by routing all requests through a CDN even if you’re not caching pages at the edge. cdn to your data center uses highly optimized TCP protocols to speed up your packets.

I thought you meant you were making $5/mo and was thinking "that is a low bar even I could prob achieve". Nice that you've pared down and optimized your stack to serve up customers with a tiny box.

Have you looked at the Hotwire stuff that came out for Rails? Basically it lets you server render pages but deliver request 2-N over web sockets, and it just delivers the bits that changed, per how you specify. There is client side JS needed but its batteries included.

I wonder if your app (and other cloud hosted) would benefit financially more with lower network ingress/egress byte counts and costs since it is page snippets instead of full-on JSON payloads like traditional JSFramework<->XHR<->JSON<->Backend stacks.