Database Setup
Payblocks is based on Payload CMS, that is database agnostic, meaning you can use any type of database behind Payload’s familiar APIs. Nevertheless, we try to keep Payblocks production ready and therefore can’t support all database clients at this time. This page is explaining the official support and how to replace the offical adapters with your own.
Install MongoDB Locally on Mac
The official MongoDB installation guide is available at https://www.mongodb.com/docs/manual/tutorial/install-mongodb-on-os-x/
Installing MongoDB 8.0 Community Edition
brew tap mongodb/brew
brew update
To install MongoDB, run the following command in your macOS Terminal application:
brew install mongodb-community@8.0
Run MongoDB Locally on Mac
brew services start mongodb-community@8.0
Run MongoDB Locally in Docker
Better than to install MongoDB is to run it directly in docker.
docker run --name payblocks-mongodb -p 27017:27017 -v mongo-volume:/data/db -d mongo:8
Install a MongoDB debugging GUI
MongoDB Compass is a GUI for MongoDB. It is not required to run MongoDB, but it is useful for managing your MongoDB databases.
https://www.mongodb.com/try/download/compass
Alternatively, you can use the Studio 3T GUI, that works fine in the free mode: https://studio3t.com/
Information on Postgres Usage
We recommend using MongoDB for Payload. In general, Payblocks offers better support for MongoDB than for Postgres. If you choose to use Postgres, you must create and maintain database migration scripts for each content schema modification. Additionally, some of our features — such as the custom Backup and Seeding plugin — will only work with MongoDB.
Here is some documentation to help you decide, which database technology is right for you: Payload Database Documentation
If you still wish to use Postgres, you can find the official installation details here: Payload Postgres Documentation.
To see tutorials for Windows and Linux see: https://www.mongodb.com/docs/manual/installation/