[GeoNode-users] GeoNode-Project local_settings

Julierme Pinheiro juliermeopensourcedeveloper at gmail.com
Thu Jan 10 04:33:31 PST 2019


Hi Toni,
Thank you very much for your reply.
Find bellow the site working with wsgi.py configured to settings
http://192.241.135.159/

Now, going back to the issue related to wsgi.py configured to
local_settings:

Yes, checking the logs, I found out that there is an issue with SITEURL.
Please see bellow:

celery4my_geonode |     SITEURL = os.getenv('SITEURL', "http://%s:%s/" %
(SITE_HOST_NAME, SITE_HOST_PORT))
celery4my_geonode | NameError: name 'SITE_HOST_NAME' is not defined

django4my_geonode |     SITEURL = os.getenv('SITEURL', "http://%s:%s/" %
(SITE_HOST_NAME, SITE_HOST_PORT))
django4my_geonode | NameError: name 'SITE_HOST_NAME' is not defined

SITE_HOST_NAME is defined after SITEURL. *I changed from*:

SITEURL = os.getenv('SITEURL', "http://%s:%s/" % (SITE_HOST_NAME,
SITE_HOST_PORT))

# we need hostname for deployed
_surl = urlparse(SITEURL)
HOSTNAME = _surl.hostname

# per-deployment settings should go here
SITE_HOST_NAME = os.getenv('SITE_HOST_NAME', HOSTNAME)
SITE_HOST_PORT = os.getenv('SITE_HOST_PORT', "80")

*To: *

#SITEURL = os.getenv('SITEURL', "http://%s:%s/" % (SITE_HOST_NAME,
SITE_HOST_PORT))

# we need hostname for deployed
#_surl = urlparse(SITEURL)
#HOSTNAME = _surl.hostname

# per-deployment settings should go here
SITE_HOST_NAME = os.getenv('SITE_HOST_NAME', "172.21.5.187")
SITE_HOST_PORT = os.getenv('SITE_HOST_PORT', "80")

SITEURL = os.getenv('SITEURL', "http://%s:%s/" % (SITE_HOST_NAME,
SITE_HOST_PORT))

# we need hostname for deployed
_surl = urlparse(SITEURL)
HOSTNAME = _surl.hostname

But the django4my_geonode and celery4my_geonode container error remains the
same:

celery4my_geonode |     SITEURL = os.getenv('SITEURL', "http://%s:%s/" %
(SITE_HOST_NAME, SITE_HOST_PORT))
celery4my_geonode | NameError: name 'SITE_HOST_NAME' is not defined

django4my_geonode |     SITEURL = os.getenv('SITEURL', "http://%s:%s/" %
(SITE_HOST_NAME, SITE_HOST_PORT))
django4my_geonode | NameError: name 'SITE_HOST_NAME' is not defined

I appreciated your time and by the way, Happy 2019 for you all. I wish you
all health and success in all life projects.

Kind regards

Julierme


On Wed, Jan 9, 2019 at 6:18 PM Toni Schönbuchner <
toni.schoenbuchner at csgis.de> wrote:

> Hey Julierme,
>
> have you checked the output of logs?
>
> $ docker-compose logs -f
> or
> $ docker-compose logs -f django
> or
> $ docker-compose logs -f celery
>
> Cheers,
>
> Toni
>
> > ----------------------------------------------------------------------
> >
> > Message: 1
> > Date: Wed, 9 Jan 2019 11:27:59 -0200
> > From: Julierme Pinheiro <juliermeopensourcedeveloper at gmail.com>
> > To: geonode-users <geonode-users at lists.osgeo.org>
> > Subject: [GeoNode-users] GeoNode-Project local_settings
> > Message-ID:
> >       <CAKTKyJJ_6KV9d=
> zikW9SAj6bybDCD+p8-XT7OuDZL7QxGxVVzw at mail.gmail.com>
> > Content-Type: text/plain; charset="utf-8"
> >
> > Dear all,
> >
> > I am running an Ubuntu 18.04 LTS VM. I am trying to install
> > GeoNode-Project at 2.8 via Docker following the instructions in here.
> > <https://github.com/GeoNode/geonode-project/tree/2.8>
> > By changing wsgi.py to local_settings, celery4my_geonode and
> > django4my_geonode won't start and I am always getting the *502 Bad
> Gateway*
> > response in the browser.
> >
> > Has anyone faced the same issue and could guide me on how to solve it?
> >
> > Thank you for your time in advance
> >
> > Regards
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/geonode-users/attachments/20190110/6c7233fc/attachment.html>


More information about the geonode-users mailing list