Open elimisteve opened 6 years ago
Packaging a Cloudron app indeed looks easy, though they may assume a single-process backend: https://cloudron.io/developer/packaging/
If that becomes an issue, we could create one Dockerfile that spins up the Go binary, PostgREST, and maybe Postgres using a technique such as https://docs.docker.com/config/containers/multi-service_container/ .
Cloudron has addons, including Postgres 9.5.5: https://cloudron.io/developer/addons/#postgresql
We could ship a very small Pursuance Cloudron app that includes a PostgREST binary that somehow optionally gets its Postgres connection info from the Cloudron-provided environment variables (e.g., POSTGRESQL_URL
), a Go binary (called pursuance
), and a folder of static assets (namely the JS and CSS bundles, and a few images).
EDIT: This actually fits really well with what we may end up doing with our default, perhaps containerized server installation, where Postgres sits outside of a container but the Go and PostgREST binaries don't.
Scaleway lets users paste in cloudinit JSON. Maybe we can create a cloudinit config that spins up a Pursuance instance???
cloudinit lets one create arbitrary files (see https://cloudinit.readthedocs.io/en/latest/topics/examples.html#writing-out-arbitrary-files ) which we can perhaps have run on boot?
EDIT: Can also run chef or puppet ~recipes: https://cloudinit.readthedocs.io/en/latest/topics/examples.html#install-and-run-chef-recipes
Finally found a great solution! If we pay Scaleway ~$3/month then we can join their "developer program", which lets us push custom machine images to their ImageHub that Scaleway customers can then launch using
https://www.scaleway.com/developer/
https://www.scaleway.com/imagehub/
https://github.com/scaleway/docker-machine-driver-scaleway
https://github.com/machine-drivers/?utf8=%E2%9C%93&q=docker-machine-driver-&type=&language=
Approaches
Do what Perkeep does here, but for clouds that aren't Google-controlled: https://perkeep.org/launch/
Convince DigitalOcean to create a One-click Install server image for Pursuance
Let users paste in a DO API key, then use it to spin up an instance for people
Work on Cloudron?
Other Notes
DNS is generally a problem, particularly enabling users to easily host a Pursuance instance using their own domain
Especially in light of the DNS issue just mentioned, if a semi-technical person needs to be involved anyway, perhaps the planned easy-to-run container-based deployment flow is good enough (see #86)?