How can I connect on-premise to database running in RDS?

I’m trying to set up on-premise to work with a Postgres DB running in RDS and I could use some help understanding the minimum steps I should take to accomplish this.

So far I’ve copied to and updated the DATABASES dict to look like this:

    "default": {
        "ENGINE": "django.db.backends.postgresql",
        "NAME": "pg-name",
        "USER": "fake_myuser",
        "PASSWORD": "fake_password",
        "HOST": "",
        "PORT": "5432",

I chose the value for ENGINE based on the recommendation in the output of sentry_install_log-<date>.txt.

Am I on the right track here? Are there other changes I have to make to my docker-compose.yml file?

When I run the install script with the --no-user-prompt flag, it seems to get stuck. The last line of output (several lines under Setting up database) is

[WARNING] sentry.utils.geo: settings.GEOIP_PATH_MMDB not configured.

The only other customization I’ve made to the on-premise install is to update the nginx.conf and docker-compose file to redirect HTTP traffic on port 80 to port 443.

Sorry if there are any details I forgot to include, but any help getting on track would be appreciated!


You seem to be on the right track. If you are using an external Postgres instance tho, I’d say remove all references to the postgres service from the dockes-compose.yml file and the script.

Seems like the install script has a bug with --no-user-prompt flag: For now, just set the CI env variable to 1 to make it non-interactive.

Once you reach the setting up databases step, it should continue with the migrations. The warning you shared is harmless and irrelevant.

The issue might be a timeout or slow connection to your RDS instance if it seems to be stuck with no more output.

1 Like