Hacker News new | ask | show | jobs
by jonwayne 3593 days ago
You can use Postgres and Redis. :) I'm working on writing new tutorials for both of those, but in the meantime:

You can host your own Postgres on Compute Engine [1] or use a hosted provider like ElephantSQL [2]. You can use whatever client library you want to connect to postgres in App Engine flexible.

Same story for redis - you can host it on Compute Engine [3] or use something like redislabs.

[1] https://cloud.google.com/solutions/set-up-postgres

[2] https://www.elephantsql.com/

[3] https://cloud.google.com/launcher/?q=redis

[4] https://redislabs.com/

Note: I'm in Developer Relations for Google Cloud Platform

3 comments

that's not the same as fully managed postgresql (which only aws has (at the time)) elpahntsql is not really cheap compared to aws master-slave.

Just comparing the smallest instances, elephantsql:

- db.t2.micro 1 year 20 USD / month (250 USD upfront) - 24.82 USD monthly (that's a multi-slave with auto failover) compared (with 30gb (SSD) storage it's at 30 USD) to elephantsql only 2GB data on a shared database server 20 USD

- db.t2.small 1 year 41 USD / month (500 USD upfront) - 50 USD monthly (that's a multi-slave with auto failover) (with storage around ~60 USD) vs elephantsql Happy Hippo single dedicated database 99 USD 100gb data

you kidding right? I would need to pay twice the price.

Both of those third party providers look interesting. Thanks for pointing them out.

Edit:

I notice that ElephantSQL doesn't surface in a partner search but EnterpriseDB does.

https://cloud.google.com/partners/#?q=postgresql

EnterpriseDB seems relatively expensive, even when just getting started (Estimated costs: $891.00/month).

https://console.cloud.google.com/launcher/details/public-edb...

Redis is provided by Click to Deploy, i.e. "Popular open stacks on Google Compute Engine packaged by Google", and is in beta (Estimated costs: $307.80/month).

https://console.cloud.google.com/launcher/details/click-to-d...

Looks like Redis Labs has a trivial free tier, and the 1GB plan is cheaper on GCE than AWS ($57/mo vs. $71/mo). I'm pretty annoyed that I had to create a Redis Labs account to see that though.

How do you deal with securing the DB's in this setup? Is it possible to isolate the compute engine DB ports to only your appengine instances, or do they have to be open to the whole world?
App Engine Flexible runs on GCE instances, which all have internal IPs. So you can just firewall off external traffic but allow internal, which is the default anyway.

Disclosure: Also GCP Developer Relations

OK great - thanks. Just to be clear, you'd still be opening up DB ports to all internal global GCE instances?
Global GCE instances within your project, yes. Not every GCE instance everywhere, that would not be very helpful :)

If you wanted to have some instances that couldn't talk to your database, easiest thing to do is probably throw them in a separate project or create a new subnet that you firewall off and create your non-App Engine instances in that subnet.