Merge pull request #145 from dimasciput/production

Changes from production server
This commit is contained in:
Dimas Ciputra authored and GitHub committed 2017-11-28 17:16:10 +07:00
commit 35a06cb976
5 files changed
+159 -9

No files matched your search

+148
View File
@@ -182,3 +182,151 @@ IMPORT_TASK_SOFT_TIME_LIMIT = 90
MAX_CSV_RECORDS = 20000
DEBUG = True
MAPBOX_ACCESS_TOKEN = os.environ.get('MAPBOX_ACCESS_TOKEN', None)
MAP_BASELAYERS = [
{
'args': [
'No background',
],
'fixed': True,
'group': 'background',
'name': 'background',
'source': {
'ptype': 'gxp_olsource',
'url': 'http://haitidata.org/api/geoserver/wms',
},
'type': 'OpenLayers.Layer',
'visibility': False,
},
{
'fixed': True,
'group': 'background',
'name': 'mapnik',
'source': {
'ptype': 'gxp_osmsource',
},
'type': 'OpenLayers.Layer.OSM',
'visibility': True,
},
{
'args': [
'Mapbox Satellite',
[
'https://api.mapbox.com/v4/mapbox.satellite/${z}/${x}/${y}.png?access_token=' + str(
MAPBOX_ACCESS_TOKEN),
],
{
'transitionEffect': 'resize',
'attribution': 'Mapbox'
}
],
'type': 'OpenLayers.Layer.XYZ',
'source': {
'ptype': 'gxp_olsource',
},
'visibility': True,
'fixed': True,
'group': 'background',
},
{
'args': [
'Mapbox Outdoors',
[
'https://api.mapbox.com/v4/mapbox.outdoors/${z}/${x}/${y}.png?access_token=' + str(
MAPBOX_ACCESS_TOKEN),
],
{
'transitionEffect': 'resize',
'attribution': 'Mapbox'
}
],
'type': 'OpenLayers.Layer.XYZ',
'source': {
'ptype': 'gxp_olsource',
},
'visibility': True,
'fixed': True,
'group': 'background',
},
{
'args': [
'Mapbox Dark',
[
'https://api.mapbox.com/v4/mapbox.dark/${z}/${x}/${y}.png?access_token=' + str(
MAPBOX_ACCESS_TOKEN),
],
{
'transitionEffect': 'resize',
'attribution': 'Mapbox'
}
],
'type': 'OpenLayers.Layer.XYZ',
'source': {
'ptype': 'gxp_olsource',
},
'visibility': True,
'fixed': True,
'group': 'background',
},
{
'args': [
'Mapbox Light',
[
'https://api.mapbox.com/v4/mapbox.light/${z}/${x}/${y}.png?access_token=' + str(
MAPBOX_ACCESS_TOKEN),
],
{
'transitionEffect': 'resize',
'attribution': 'Mapbox'
}
],
'type': 'OpenLayers.Layer.XYZ',
'source': {
'ptype': 'gxp_olsource',
},
'visibility': True,
'fixed': True,
'group': 'background',
},
{
'args': [
'Mapbox Streetmap',
[
'https://api.mapbox.com/v4/mapbox.streets/${z}/${x}/${y}.png?access_token=' + str(
MAPBOX_ACCESS_TOKEN),
],
{
'transitionEffect': 'resize',
'attribution': 'Mapbox'
}
],
'type': 'OpenLayers.Layer.XYZ',
'source': {
'ptype': 'gxp_olsource',
},
'visibility': True,
'fixed': True,
'group': 'background',
},
{
'args': [
'Mapbox Satellite Streetmap',
[
'https://api.mapbox.com/styles/v1/mapbox/satellite-streets-v9/tiles/256/${z}/${x}/${y}?access_token=' + str(
MAPBOX_ACCESS_TOKEN),
],
{
'transitionEffect': 'resize',
'attribution': 'Mapbox'
}
],
'type': 'OpenLayers.Layer.XYZ',
'source': {
'ptype': 'gxp_olsource',
},
'visibility': True,
'fixed': True,
'group': 'background',
},
]
+3 -3
View File
@@ -9,14 +9,14 @@ GEOSERVER_PUBLIC_LOCATION = os.environ.get(
os.environ.get('SITEURL') + 'api/geoserver/'
)
GEOSERVER_DEV_URL = 'http://136.243.4.93:8080/geoserver/'
# dynamic setting based on domain
GEOSERVER_BASE_URL = os.environ.get(
'GEOSERVER_BASE_URL',
'http://0.0.0.0:8080/geoserver/'
) # change this to geoserver container location
GEOSERVER_DEV_URL = GEOSERVER_BASE_URL
GEOSERVER_LOCATION = os.environ.get(
'GEOSERVER_LOCATION',
'http://geoserver:8080/geoserver/'
@@ -101,4 +101,4 @@ SOCIAL_ORIGINS = [{
"css_class": "gp"
}]
WCS_DOWNLOADED_RATIO_SIZE = 1
WCS_DOWNLOADED_RATIO_SIZE = 1
@@ -6,9 +6,9 @@
{% block title %}{{ block.super }}{% endblock %}
{% block page-title %}
{% if geotiffname == 'ortho_images' %}
{% if geotiffname == 'ortho_images_pyramid' %}
Ortho Photos
{% elif geotiffname == 'lidar' %}
{% elif geotiffname == 'lidar_dem_mosaic' %}
{% trans "DSM" %}
{% endif %}
{% endblock %}
@@ -19,7 +19,7 @@
<div class="row">
<div class="col-md-12">
<article id="info">
{% if geotiffname == 'ortho_images' %}
{% if geotiffname == 'ortho_images_pyramid' %}
<p>Les <strong>orthophotographies</strong> ou <strong>orthoimages</strong> sont des images aériennes ou satellitales de la surface terrestre rectifiées géométriquement et égalisées radiométriquement. Ces images se présentant sous forme de dalles couvrant une zone de la Terre peuvent être géoréférencées dans n'importe quel système de coordonnées. Elles servent de fonds cartographiques dans les Systèmes d'information géographique.</p>
{% else %}
<p>Un Modèle Numérique de Terrain (MNT) est une représentation 3D de la surface d'un terrain ou d'une planète, créée à partir des données d'altitude du terrain."</p>
+2 -2
View File
@@ -79,8 +79,8 @@
<li id="nav_imagery">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">{% trans "Imagery" %}<i class="fa fa-angle-down fa-lg"></i></a>
<ul class="dropdown-menu">
<li><a href="/clip/ortho_images">{% trans "Orthophotos" %}</a></li>
<li> <a href="/clip/lidar">{% trans "DSM" %}</a></li>
<li><a href="/clip/ortho_images_pyramid">{% trans "Orthophotos" %}</a></li>
<li> <a href="/clip/lidar_dem_mosaic">{% trans "DSM" %}</a></li>
</ul>
</li>
<li>
+3 -1
View File
@@ -1,5 +1,6 @@
from django.contrib import admin
from geonode.sitemap import LayerSitemap, MapSitemap
from django.views.generic.base import RedirectView
import autocomplete_light
@@ -25,13 +26,14 @@ urlpatterns = patterns(
'',
url(r'^/?$', TemplateView.as_view(template_name='site_index.html'), name='home'),
url(r'^layers/(?P<layername>[^/]*)/thumbnail$', layer_thumbnail, name='layer_thumbnail2'),
(r'^maps/\[object Object\]/geoserver/wms$', RedirectView.as_view(url='/geoserver/wms',query_string=True)),
url(r'^', include('geonode.urls')),
url(r'', include(api_ext.urls)),
url(r'^chart/', include('charts_app.urls')),
url(r'^table/', include('wfs_harvest.urls')),
url(r'^clip/', include('clip-and-ship.urls')),
url(r'^contact/$', TemplateView.as_view(template_name='contact.html'), name='contact'),
url(r'^tutorials/$', TemplateView.as_view(template_name='tutorials.html'), name='tutorials'),
url(r'^tutorials/$', TemplateView.as_view(template_name='tutorials.html'), name='tutorials'),
)
urlpatterns += patterns(
'',