DEV Community

Discussion on: Deploying GeoDjango applications on heroku: Easy workthrough

 
mojemoron profile image
Micheal Ojemoron

I added that when i discovered the issue, removing it still reproduces the issue. I am on Django 3.2.1 and Heroku 20

Thread Thread
 
sirneij profile image
John Owolabi Idogun

Did you add any buildpack aside the default one heroku gives?

Thread Thread
 
mojemoron profile image
Micheal Ojemoron

no

Thread Thread
 
sirneij profile image
John Owolabi Idogun

GDAL can't work on heroku without you adding external buildpack to help you build Geospatial configurations. That is why I recommend you go through this article again and implement the stuff suggested. They are easy and not detrimental.

Thread Thread
 
sirneij profile image
John Owolabi Idogun • Edited

The error you are getting sterms from directing heroku to look for buildpacks and runtimes in arbitary paths that do not really exist.

Thread Thread
 
mojemoron profile image
Micheal Ojemoron

i added this heroku buildpacks:add --index 1 github.com/heroku/heroku-geo-build...
according to your article

Thread Thread
 
sirneij profile image
John Owolabi Idogun

In your settings.py, add this to the bottom of the file:

DATABASES['default']['ENGINE'] = 'django.contrib.gis.db.backends.postgis'
Enter fullscreen mode Exit fullscreen mode
Thread Thread
 
mojemoron profile image
Micheal Ojemoron

in my settings, i already added Database Engine and the error i am getting is related to the library gdal

Thread Thread
 
sirneij profile image
John Owolabi Idogun • Edited

What database are you using? And do you use heroku's dj_database_url?