Coder Social home page Coder Social logo

gfdrr / geonode Goto Github PK

View Code? Open in Web Editor NEW

This project forked from geonode/geonode

2.0 12.0 3.0 345.37 MB

GFDRR Lab GeoNode

Home Page: https://www.geonode-gfdrrlab.org

License: GNU General Public License v3.0

Shell 2.44% JavaScript 5.46% Python 68.37% HTML 17.48% CSS 3.18% Makefile 0.18% XSLT 2.77% Dockerfile 0.13%

geonode's Introduction

Coverage Badge Build Status

GeoNode Support

To get support, give feedback and suggestions please use the GeoNode official channels, the users mailing list: http://lists.osgeo.org/pipermail/geonode-users/ and the developers mailing list: http://lists.osgeo.org/pipermail/geonode-devel/.

This repository is used to track code changes and GeoNode issues, please DON'T open new issues to ask for support.

GeoNode Installation

If you just want to try GeoNode, it is recommended to use Ubuntu 14.04 and install the latest stable release of GeoNode.:

sudo add-apt-repository ppa:geonode/release
sudo apt-get update
sudo apt-get install geonode

If instead, you are interested in doing development on the source code, here are the instructions: http://docs.geonode.org/en/master/tutorials/devel/devel_env/index.html

Development Installations

Docker Usage

If you want to use Docker you can now:

# build the docker container
docker-compose build

# run the docker container
docker-compose up

# turn it off
docker-compose down

Or if you want to use the provided Makefile:

# build the container
make build

# run the container
make up

# create database
make sync

# pull latest images
make pull

Note: For deveployment you need to add geonode alias into /ect/hosts/ file as following:

` $ sudo vim /etc/hosts ## # Host Database # # localhost is used to configure the loopback interface # when the system is booting. Do not change this entry. ## 127.0.0.1 localhost geonode 255.255.255.255 broadcasthost ::1 localhost ` To access GeoNode just enter the following url: http://geonode/ on your web browser. For GeoServer: http://geonode/geoserver/web/

Ubuntu

Ubuntu development build instructions using an isolated virtual environment (tested on Ubuntu 14.04 LTS):

# Install Ubuntu dependencies
sudo apt-get update
sudo apt-get install python-virtualenv python-dev libxml2 libxml2-dev libxslt1-dev zlib1g-dev libjpeg-dev libpq-dev libgdal-dev git default-jdk

# Install Java 8 (needed by latest GeoServer 2.9)
sudo apt-add-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get install oracle-java8-installer

# Create and activate the virtualenv
virtualenv --no-site-packages env
source env/bin/activate

# git clone geonode
git clone https://github.com/GeoNode/geonode
cd geonode

# Install pip dependencies
pip install -r requirements.txt
pip install -e .
pip install pygdal==1.10.1

For Ubuntu 16.04 you should create your virtual-env like this instead (so with site packages):

virtualenv env

Instead of installing pygdal, you should do the following:

# Install the system python-gdal
sudo apt-get install python-gdal
# Create a symbolic link in your virtualenv
ln -s /usr/lib/python2.7/dist-packages/osgeo env/lib/python2.7/site-packages/osgeo

You can now setup and start GeoNode:

# Paver setup
paver setup
paver sync
paver start

In case you want to be involved in static files development:

sudo apt-get install npm
sudo npm install -g bower
sudo npm install -g grunt-cli

openSUSE

openSUSE Development Build Instructions:

# Add Application:Geo and Python repositories
zypper -ar http://download.opensuse.org/repositories/Application:/Geo/openSUSE_12.2/ GEO
zypper -ar http://download.opensuse.org/repositories/devel:/languages:/python/openSUSE_12.1/ python
zypper refresh

# Basic build packages
zypper install gcc gcc-c++ python-devel libgeos-devel libproj-devel

# Python native dependencies
zypper install python-pip python-virtualenv python-imaging python-lxml python-gdal

# Java dependencies
zypper install java-1_7_0_openjdk-devel ant maven

# Supporting tools
zypper install git gettext-runtime

# Create virtualenv and activate it
virtualenv venv --system-site-packages
source venv/bin/activate
cd venv

# Clone GeoNode
git clone https://github.com/GeoNode/geonode.git

# Install GeoNode in the local virtualenv
pip install -e geonode --use-mirrors

cd geonode

# Compile GeoServer
paver setup

# Initialize database
paver sync

# Start the servers
paver start

Windows

Windows Development Build Instructions:

Prerequisites:
# Java JDK
# Python 2.7 (32 bit)
# ant (bin directory must be on system PATH)
# maven2 (bin directory must be on system PATH)
# Python distutils (easy_install)
# GDAL Core Libraries
# git

# Install and configure from the windows command prompt
If you don't already have python virtualenv installed, then do it now:
easy_install virtualenv

# Download and install http://download.gisinternals.com/sdk/downloads/release-1800-gdal-1-11-4-mapserver-6-4-3/gdal-111-1800-core.msi
# Download and install http://download.gisinternals.com/sdk/downloads/release-1800-gdal-1-11-4-mapserver-6-4-3/GDAL-1.11.4.win32-py2.7.msi
# Choose your 32 bit python as your install target
# If you create your virtualenv before doing this, you can copy the <python>\lib\site-packages\osgeo and GDAL-* directory over to your <virtual env>\lib\site-packages directory

# Create virtualenv and activate it
cd <Directory to install the virtualenv & geonode into>
virtualenv venv
venv\scripts\activate

# Clone GeoNode
git clone https://github.com/GeoNode/geonode.git

# Install compiled packages for Python 2.7 Win32
cd geonode
pip install paver
pip install pyyaml
paver win_install_deps

# Install GeoNode in the local virtualenv, if you get an error about use-mirrors, just remove the argument
pip install -e . --use-mirrors

# Note, you may get errors due to certain dependencies not being installable on windows with pip, such as lxml and shapely.
# For these, you can download a whl file (use cp27 / win32 version) from http://www.lfd.uci.edu/~gohlke/pythonlibs and then install them via pip.
# Ex: pip install <Download Dir>\Shapely-1.5-16-cp27-cp27m-win32.whl
#
# Also note, you may have to adjust the dependencies in geonode\setup.py to say >= instead of ==,
# ie "Shapely>=1.5.13", instead of "Shapely==1.5.13",

# Compile GeoServer
paver setup

# Set GDAL environment info
SET GDAL_LIBRARY_PATH=<GdalPath>\gdal111.dll
SET GDAL_HOME=<GdalPath>
SET GEOS_LIBRARY_PATH=<GdalPath>\geos_c.dll
SET PATH=<GdalPath>;%PATH%

# Initialize database
paver sync

# Start the servers
paver start --java_path=C:/path/to/java/bin/java.exe

Mac OSX

Mac OSX Development Build Instructions:

# you may need brew install various dependencies

mkdir -p ~/pyenv
virtualenv ~/pyenv/geonode
source ~/pyenv/geonode/bin/activate
git clone https://github.com/GeoNode/geonode
cd geonode
pip install lxml
pip install pyproj
pip install nose
pip install httplib2
pip install shapely
pip install pillow
pip install paver

# Node and tools required for static development
brew install node
npm install -g bower
npm install -g grunt-cli

#Install pip dependencies
pip install -e .

#Paver handles dependencies for Geonode, first setup (this will download and update your python dependencies - ensure you're in a virtualenv)
paver setup
paver sync
paver start

# Optional: To generate document thumbnails for PDFs and other ghostscripts file types
# Then download ghostscript: https://www.macupdate.com/app/mac/9980/gpl-ghostscript
brew install imagemagick
pip install Wand==0.3.5

Once fully started, you should see a message indicating the address of your geonode. The default username and password are admin and admin:

Development Geonode is running at http://localhost:8000/
To stop the GeoNode machine run:
paver stop

Or quit the server by pressing
CTRL-C to shut down

Before starting GeoNode (paver start), you could test your installation by running tests:

paver test
paver test_integration

In case you want to build yourself the documentation, you need to install Sphinx and the run 'make html' from within the docs directory:

pip install Sphinx
pip install sphinx_rtd_theme
cd docs
make html

You can eventually generate a pdf containing the whole documentation set. For this purpose, if using Ubuntu you will need to install the texlive-full package:

sudo apt-get install texlive-full
make latexpdf

Note

When running virtualenv venv the --system-site-packages option is not required. If not enabled, the bootstrap script will sandbox your virtual environment from any packages that are installed in the system, useful if you have incompatible versions of libraries such as Django installed system-wide. On the other hand, most of the times it is useful to use a version of the Python Imaging Library provided by your operating system vendor, or packaged other than on PyPI. When in doubt, however, just leave this option out.

Development Roadmap

Geonode's development roadmap is documented in a series of Geonode Improvement Projects (GNIPS). They are documented here: https://github.com/GeoNode/geonode/wiki/GeoNode-Improvement-Proposals. GNIPS are considered to be large undertakings which will add a large amount of features to the project. As such they are the topic of community dicussion and guidance. The community discusses these on the developer mailing list: http://lists.osgeo.org/pipermail/geonode-devel/ Github issues tracks features and bugs, for new developers the tag 'easy-pick' indicates an issue that should be relatively easy for new developers to understand and complete. Once you have completed an issue a pull request should be submitted. This will then be reviewed by the community.

GPL License

GeoNode is Copyright 2016 Open Source Geospatial Foundation (OSGeo).

GeoNode is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

GeoNode is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with GeoNode. If not, see <http://www.gnu.org/licenses/>.

geonode's People

Contributors

ahocevar avatar b-angerer avatar capooti avatar cspanring avatar davelowe avatar dwins avatar francbartoli avatar garnertb avatar groldan avatar ingenieroariel avatar ischneider avatar iwillig avatar jj0hns0n avatar kalxas avatar lukeman avatar mbertrand avatar mdiener21 avatar menegon avatar mweisman avatar mwengren avatar pjdufour avatar ppasq avatar sarasafavi avatar sbenthall avatar simod avatar state-hiu-dev avatar teamgeode avatar tomkralidis avatar travislbrundage avatar vampouille avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

geonode's Issues

Cache not logging new styles

Many layers that I have changed are showing up in the thumbnails properly. One layer in particular I updated days ago, and it still is not appearing correctly in the thumbnail.

Select all layers

We would like to add a feature that enables user to select all layers that have been filtered by search box, instead of selecting each one individually

Cannot create new layer

On http://54.229.171.111/layers/upload

capture du 2017-03-31 16-28-21

Looks like geonode is not authorized to push data into geoserver using the rest API.

Current security/rest.properties config is:

/rest/process/batchdownload/download/*;GET=IS_AUTHENTICATED_ANONYMOUSLY         
/rest/printing/*;GET,POST=IS_AUTHENTICATED_ANONYMOUSLY                          
/**;GET=ADMIN                                                                   
/**;POST,DELETE,PUT=ADMIN

[int] geoserver startup failure

We migrated the datadir to oauth2 (comparing the current datadir to http://build.geonode.org/geoserver/latest/data-2.9.x-oauth2.zip + replacing localhost:8000 with django:8000) but now geoserver refuses to start with

java.lang.UnsatisfiedLinkError: /usr/local/tomcat/temp/spatialite-3.7.22.4-libspatialitejdbc.so: libgeos_c.so.1: cannot open shared object file: No such file or directory
08:25:38,246 |-INFO in ch.qos.logback.core.db.DataSourceConnectionSource@3d6efb3d - Driver name=SQLiteJDBC
08:25:38,246 |-INFO in ch.qos.logback.core.db.DataSourceConnectionSource@3d6efb3d - Driver version=native
08:25:38,246 |-INFO in ch.qos.logback.core.db.DataSourceConnectionSource@3d6efb3d - supportsGetGeneratedKeys=true
23-May-2017 08:25:59.767 WARNING [localhost-startStop-1] org.apache.catalina.loader.WebappClassLoaderBase.clearReferencesThreads The web application [geoserver] appears to have started a thread named [Timer-0] but has failed to stop it. This is very likely to create a memory leak. Stack trace of thread:
 java.lang.Object.wait(Native Method)
 java.util.TimerThread.mainLoop(Timer.java:552)
 java.util.TimerThread.run(Timer.java:505)
23-May-2017 08:25:59.769 WARNING [localhost-startStop-1] org.apache.catalina.loader.WebappClassLoaderBase.clearReferencesThreads The web application [geoserver] appears to have started a thread named [FileSystemWatcher-1] but has failed to stop it. This is very likely to create a memory leak. Stack trace of thread:
 sun.misc.Unsafe.park(Native Method)
 java.util.concurrent.locks.LockSupport.parkNanos(LockSupport.java:215)
 java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.awaitNanos(AbstractQueuedSynchronizer.java:2078)
 java.util.concurrent.ScheduledThreadPoolExecutor$DelayedWorkQueue.take(ScheduledThreadPoolExecutor.java:1093)
 java.util.concurrent.ScheduledThreadPoolExecutor$DelayedWorkQueue.take(ScheduledThreadPoolExecutor.java:809)
 java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1067)
 java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1127)
 java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
 java.lang.Thread.run(Thread.java:745)
23-May-2017 08:25:59.775 SEVERE [localhost-startStop-1] org.apache.catalina.loader.WebappClassLoaderBase.checkThreadLocalMapForLeaks The web application [geoserver] created a ThreadLocal with key of type [java.lang.ThreadLocal] (value [java.lang.ThreadLocal@45c859d0]) and a value of type [org.springframework.security.core.context.SecurityContextImpl] (value [org.springframework.security.core.context.SecurityContextImpl@ffffffff: Null authentication]) but failed to remove it when the web application was stopped. Threads are going to be renewed over time to try and avoid a probable memory leak.
23-May-2017 08:25:59.854 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deployment of web application directory /usr/local/tomcat/webapps/geoserver has finished in 78,431 ms

Seems like libspatialitejdbc is missing in the image

new metadata field ‘Data coverage reference’

Add new metadata field, for layer used in TH! Called ‘Data coverage reference’.

This would contain standard text referring to the coverage of the data, e.g., ‘National’. This field would be extracted with the data owner and/or layer title using the Geonode list views, and built into scripts to update the shp and geojson map file (by GFDRR).
Update on TH would still have to be via github request, but this would streamline update process on admin side.

[int] GeoServer could not find layers

24 May 12:17:48 ERROR [geoserver.ows] - 
org.geoserver.platform.ServiceException: Could not find layer hazard:pga100v2
--
24 May 12:17:48 ERROR [geoserver.ows] - 
org.geoserver.platform.ServiceException: Could not find layer hazard:pga2475v2
--
24 May 12:17:48 ERROR [geoserver.ows] - 
org.geoserver.platform.ServiceException: Could not find layer hazard:pga975v2
--
24 May 12:17:48 ERROR [geoserver.ows] - 
org.geoserver.platform.ServiceException: Could not find layer hazard:pga475v2

Add data categories

We require some more meaningful data categories for the data we're uploading. Please add:

  • Risk analysis - exposure data
  • Risk analysis - hazard data
  • Risk analysis - vulnerability data
  • Risk analysis - risk output data

Issue with the search

Two issues:

  • the auto-suggested answer are hiding the text box so the user cannot see what he/she is typing in the text box after entering the first few characters
  • the search doesn't let the user enter free text, it will replace with the automatic suggestion. For instance, try entering Ethiopia. It is not possible do a search on the word "Ethiopia"

Homepage additions - risk and vulnerability data

A banner for each of 'Risk' and 'Vulnerability' should also be added but we need to think of categories and icons for these. Under Risk, I would propose a combination of the hazard and exposure icons; for vulnerability, I would propose two categories at this stage (Socioeconomic, and Structural)

batch upload to geonode

@Vampouille @fvanderbiest
Please can you confirm whether the new Geonode has full functionality to enable batch upload of layers?

On http://45.55.174.20/ we would copy files from local to a tmp folder on server, then import a batch using:
cd /var/www/geonode/wsgi/geonode
python manage.py importlayers

Has this been replicated on 54.229.171.111/ ?

Please also confirm that files/folders in 54.229.171.111//mnt/geoserver_geodata/hazard are not required, once files have been uploaded to /mnt/apache_nas_data/uploaded
I believe this is the case.

TH using data on non-Labs Geonode

We would like to access and use, in both ThinkHazard and GeoSAFE, data that resides on a GeoNode external to the Labs GeoNode. Specifically (and for now limited to) http://disasterrisk.af.geonode.org

Can we access the data via OGC and have ThinkHazard perform its calculations / GeoSAFE do the overlay analysis or do we need to make a full copy of the data and host it on Labs GeoNode in order to do this?

@cgiovando advises

  • reading metadata should be straightforward, just pointing to the xml endpoint of each layer.
  • for calculations, did they implement through a standard Web Processing Service (WPS) or is it custom built? For the current data, is TH! downloading it entirely locally to perform the calculation or is it done on the fly?
  • displaying raster layers will also be a simple WMTS call unless they are using a different protocol

Requesting input from Camptocamp @fvanderbiest , Kartoza @gubuntu, GeoSolutions @afabiani, and @jj0hns0n

[int] map printing ko

POST http://int.geonode-gfdrrlab.org/geoserver/pdf/create.json

{"units":"m","srs":"EPSG:900913","layout":"A4 portrait","dpi":75,"outputFilename":"GeoExplorer-print","comment":"dbdfd","mapTitle":"ddf","layers":[{"baseURL":"http://int.geonode-gfdrrlab.org/geoserver/wms?SERVICE=WMS&","opacity":1,"singleTile":false,"type":"WMS","layers":["hazard:_2014_1hz10pct50yrs"],"format":"image/png","styles":[""],"customParams":{"TRANSPARENT":true,"TILED":true}}],"pages":[{"center":[-9910880.4571768,4300567.2297349],"scale":4000000,"rotation":0}],"legends":[{"name":"","classes":[{"name":"","icons":["http://int.geonode-gfdrrlab.org/geoserver/wms?request=GetLegendGraphic&width=20&height=20&layer=hazard%3A_2014_1hz10pct50yrs&transparent=true&format=image%2Fpng&legend_options=fontAntiAliasing%3Atrue%3BfontSize%3A11%3BfontName%3AArial&SCALE=4000000"]}]}]}
Error while generating PDF:
com.itextpdf.text.DocumentException: org.mapfish.print.InvalidJsonValueException: spec.layers[0].baseURL has an invalid value: http://int.geonode-gfdrrlab.org/geoserver/wms?SERVICE=WMS& (org.mapfish.print.config.BasicAuthSecurity cannot be cast to org.mapfish.print.config.HostMatcher)
	at com.itextpdf.text.pdf.PdfDocument.add(PdfDocument.java:786)
	at com.itextpdf.text.Document.add(Document.java:278)

Metadata detail: incorrect display of items / titles

  • Title 'Information of Layer' misaligned
  • Title 'References' misaligned
  • Title 'Contact Points' misaligned
  • Title 'Metadata Author' misaligned

In 'Information of Layer' section:

  • coordinates, projection items misaligned with field names

In 'References' section:

  • Fix multiple Repeated layer formats

document thumbnail

Document thumbnail should display title page of pdf documents. Currently shows some default text, no image. @vdeparday please provide the links to required item to install to enable this.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.