Skip to content

Commit

Permalink
[Settings] Restoring /gs to /geoserver by default
Browse files Browse the repository at this point in the history
  • Loading branch information
afabiani committed Jun 3, 2019
1 parent b5626f9 commit f0ff9d7
Show file tree
Hide file tree
Showing 8 changed files with 13 additions and 13 deletions.
4 changes: 2 additions & 2 deletions docker-compose.override.localhost.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ services:
- GEONODE_LB_PORT=80
- SITEURL=http://localhost/
- ALLOWED_HOSTS=['localhost', ]
- GEOSERVER_PUBLIC_LOCATION=http://localhost/gs/
- GEOSERVER_PUBLIC_LOCATION=http://localhost/geoserver/
- GEOSERVER_WEB_UI_LOCATION=http://localhost/geoserver/

celery:
Expand All @@ -27,7 +27,7 @@ services:
- GEONODE_LB_PORT=80
- SITEURL=http://localhost/
- ALLOWED_HOSTS=['localhost', ]
- GEOSERVER_PUBLIC_LOCATION=http://localhost/gs/
- GEOSERVER_PUBLIC_LOCATION=http://localhost/geoserver/
- GEOSERVER_WEB_UI_LOCATION=http://localhost/geoserver/

geoserver:
Expand Down
4 changes: 2 additions & 2 deletions docker-compose.override.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ services:
- GEONODE_LB_PORT=80
- SITEURL=http://localhost/
- ALLOWED_HOSTS=['localhost', ]
- GEOSERVER_PUBLIC_LOCATION=http://localhost/gs/
- GEOSERVER_PUBLIC_LOCATION=http://localhost/geoserver/
- GEOSERVER_WEB_UI_LOCATION=http://localhost/geoserver/

celery:
Expand All @@ -27,7 +27,7 @@ services:
- GEONODE_LB_PORT=80
- SITEURL=http://localhost/
- ALLOWED_HOSTS=['localhost', ]
- GEOSERVER_PUBLIC_LOCATION=http://localhost/gs/
- GEOSERVER_PUBLIC_LOCATION=http://localhost/geoserver/
- GEOSERVER_WEB_UI_LOCATION=http://localhost/geoserver/

geoserver:
Expand Down
4 changes: 2 additions & 2 deletions geonode/local_settings.py.geoserver.sample
Original file line number Diff line number Diff line change
Expand Up @@ -72,10 +72,10 @@ GEOSERVER_PUBLIC_HOST = os.getenv(
)

GEOSERVER_PUBLIC_PORT = os.getenv(
'GEOSERVER_PUBLIC_PORT', SITE_HOST_PORT
'GEOSERVER_PUBLIC_PORT', 8080
)

_default_public_location = 'http://{}:{}/gs/'.format(GEOSERVER_PUBLIC_HOST, GEOSERVER_PUBLIC_PORT) if GEOSERVER_PUBLIC_PORT else 'http://{}/gs/'.format(GEOSERVER_PUBLIC_HOST)
_default_public_location = 'http://{}:{}/geoserver/'.format(GEOSERVER_PUBLIC_HOST, GEOSERVER_PUBLIC_PORT) if GEOSERVER_PUBLIC_PORT else 'http://{}/geoserver/'.format(GEOSERVER_PUBLIC_HOST)

GEOSERVER_WEB_UI_LOCATION = os.getenv(
'GEOSERVER_WEB_UI_LOCATION', GEOSERVER_LOCATION
Expand Down
2 changes: 1 addition & 1 deletion geonode/security/tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -717,7 +717,7 @@ def test_layer_permissions(self):
# would work only on PostGIS layers

# test change_layer_style
url = 'http://localhost:8000/gs/rest/workspaces/geonode/styles/san_andres_y_providencia_poi.xml'
url = 'http://localhost:8080/geoserver/rest/workspaces/geonode/styles/san_andres_y_providencia_poi.xml'
sld = """<?xml version="1.0" encoding="UTF-8"?>
<sld:StyledLayerDescriptor xmlns:sld="http://www.opengis.net/sld"
xmlns:gml="http://www.opengis.net/gml" xmlns:ogc="http://www.opengis.net/ogc"
Expand Down
2 changes: 1 addition & 1 deletion scripts/docker/env/production/celery.env
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ IS_CELERY=true
C_FORCE_ROOT=1
SITEURL=http://localhost/
# replaced with defaults in settings
GEOSERVER_PUBLIC_LOCATION=http://localhost/gs/
GEOSERVER_PUBLIC_LOCATION=http://localhost/geoserver/
GEOSERVER_WEB_UI_LOCATION=http://localhost/geoserver/
GEOSERVER_LOCATION=http://geoserver:8080/geoserver/
OGC_REQUEST_TIMEOUT=300
Expand Down
2 changes: 1 addition & 1 deletion scripts/docker/env/production/django.env
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ IS_CELERY=false
C_FORCE_ROOT=1
SITEURL=http://localhost/
# replaced with defaults in settings
GEOSERVER_PUBLIC_LOCATION=http://localhost/gs/
GEOSERVER_PUBLIC_LOCATION=http://localhost/geoserver/
GEOSERVER_WEB_UI_LOCATION=http://localhost/geoserver/
GEOSERVER_LOCATION=http://geoserver:8080/geoserver/
OGC_REQUEST_TIMEOUT=300
Expand Down
6 changes: 3 additions & 3 deletions scripts/spcgeonode/django/initialize.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@
admin_email,
admin_password
)
print('superuser successfully created')
print('superuser successfully created')


#########################################################
Expand All @@ -87,8 +87,8 @@
authorization_grant_type='authorization-code'
)
redirect_uris = [
'http://{}/gs'.format(os.getenv('HTTPS_HOST',"") if os.getenv('HTTPS_HOST',"") != "" else os.getenv('HTTP_HOST')),
'http://{}/gs/index.html'.format(os.getenv('HTTPS_HOST',"") if os.getenv('HTTPS_HOST',"") != "" else os.getenv('HTTP_HOST')),
'http://{}/geoserver'.format(os.getenv('HTTPS_HOST',"") if os.getenv('HTTPS_HOST',"") != "" else os.getenv('HTTP_HOST')),
'http://{}/geoserver/index.html'.format(os.getenv('HTTPS_HOST',"") if os.getenv('HTTPS_HOST',"") != "" else os.getenv('HTTP_HOST')),
]
app.redirect_uris = "\n".join(redirect_uris)
app.save()
Expand Down
2 changes: 1 addition & 1 deletion tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ def update(ctx):
'GEONODE_LB_PORT'
):
ctx.run("echo export GEOSERVER_PUBLIC_LOCATION=\
http://{public_fqdn}/gs/ >> {override_fn}".format(**envs), pty=True)
http://{public_fqdn}/geoserver/ >> {override_fn}".format(**envs), pty=True)
ctx.run("echo export GEOSERVER_WEB_UI_LOCATION=\
http://{public_fqdn}/geoserver/ >> {override_fn}".format(**envs), pty=True)
ctx.run("echo export SITEURL=\
Expand Down

0 comments on commit f0ff9d7

Please sign in to comment.