Deploy logo datasette: deploy

1 2 3 4 5 6 7

You can deploy datasette easily via the command line. There are a few cloud services natively supported but in this video we've demonstrated a demo via cloud run.

This was the command we've used;

datasette publish cloudrun bigmac.db --service=my-bigmac

Install Plugins Too

One thing to note, which we didn't show in the video, is that you need to manually specify any plugins you would like to add to your docker container. For example, if you wanted to make sure that we also get the vega visualisations you'd need to run:

datasette publish cloudrun bigmac.db --service=my-bigmac --install=datasette-vega

Other cloud providers.

You can also push to other cloud providers. Note that for all these cloud providers you'll need to have an account set up with your credit card attached. You may also need to log in using the command line tool from the provider.

Heroku

datasette publish heroku bigmac.db

Vercel

pip install datasette-publish-vercel
datasette publish vercel bigmac.db --project my-vercel-project

Fly

pip install datasette-publish-fly
datasette publish fly bigmac.db --app="bigmac-app"

Just Docker

If you're only interested in building the docker container locally (maybe you want to host the container yourself on a VM) then you can use this command:

datasette package bigmac.db