Create an minimal API using PostgREST for a webshop. This is a toy project to learn PostgREST, unlikely to be production-ready anytime soon.
Create order_api.conf
, and make it writable by the PostgreSQL superuser.
touch order_api.conf
sudo chown postgres order_api.conf
Run install.sh as the PostgreSQL superuser. Add the name of the database to be created as an argument.
sudo -u postgres ./install.sh orders
Remove write rights of PostgreSQL superuser.
Change ownership to the one running PostgREST. In this example, it is johnnie.
sudo chown johnnie order_api.conf
postgrest order_api.conf