There are two ways to configure Re-Earth. One option is to place a .env file in the Re-Earth working directory. The other option is to set environment variables directly.

If you make changes to the configuration while Re-Earth is running, you will need to restart it in order to reload the configuration.

Re-Earth offers flexibility and can be combined with various configurations. Here are the main configuration options:

Note: Integrated mode combines the front-end and back-end in a single environment, while isolated mode separates them into different environments.

Database (MongoDB)

REEARTH_DB accepts the connection string of MongoDB. The default value is mongodb://localhost.

MongoDB running on your local host

No configuration is required, but if you want to change the port,

REEARTH_DB=mongodb://localhost:20000

MongoDB Atlas

First, check the connection string of your database such as mongodb+srv://hogehoge on the Mongo Atlas admin page.

REEARTH_DB=mongodb+srv://hogehoge

Mode

Integrated mode

No configuration is required.

Isolated mode

Specify REEARTH_HOST_WEB as the URL where the front-end application is deployed.