[Geomoose-users] GeoMOOSE and Unix - getting started

James Klassen klassen.js at gmail.com
Wed Jan 15 13:12:45 PST 2014


On 2014/1/15 2:04 PM, Mark Volz wrote:
> Hello,
> 
> I am considering playing around with GeoMOOSE using Linux.  I also would like to experiment with compiling MapServer and preparing Apache for use with GeoMOOSE.  The documentation on the GeoMOOSE website for Linux installations seem to be tailored for people that are more familiar with compiling MapServer and working with Linux than I.  Could someone provide me a more step by step how to document for getting Linux, Apache, PHP, and MapServer ready for GeoMOOSE.   
> 
> Thank You
> 
> P.S.  If possible I would prefer to use an Ubuntu or similar Linux distribution
> 
> Mark Volz, GISP
> GIS Specialist
> 
> 
> _______________________________________________
> Geomoose-users mailing list
> Geomoose-users at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/geomoose-users
> 

It looks like the Linux Install docs need to be updated.

The MapServer that is packaged with Debian 7 (Wheezy) and those in
Ubuntu 12.04LTS and in the UbuntuGIS PPA are new enough to run GeoMoose.
 GeoMoose is also part of the OSGeo-Live project (based on XUbuntu) and
(for the time being) an example install script is available here:

http://svn.osgeo.org/osgeo/livedvd/gisvm/trunk/bin/install_geomoose.sh

(If you want to build MapServer 6.4 or newer, be aware they don't use
autoconf for building anymore so the options would need to be converted
to CMAKE format.  It looks like even the
http://mapserver.org/installation/unix.html page is slightly outdated
with a pointer to a more up to date file in the MapServer source code.)

On Debian or Ubuntu you will need the following packages (or similar) to
run GeoMoose:

apt-get install apache2 libapache2-mod-php5 \
	mapserver-bin cgi-mapserver gdal-bin \
	php5-mapscript php5-sqlite php5-gd php5-curl

Additionally, you will need the following packages to "compile" the
GeoMoose JavaScript code and to build the documentation:

apt-get install git-core \
	default-jre \
	python-sphinx make texlive texlive-latex-extra \
	naturaldocs

You can work from one of the tarballs on the download page, but to get
the most up to date version of the GeoMoose demo, clone from our github
repository as described in https://github.com/geomoose/geomoose. As git
submodules are used, the key is to "git clone --recursive" to make sure
you get the whole project.

For example:

git clone --recursive https://github.com/geomoose/geomoose.git

Will clone the latest development version of GeoMooose into a local
folder "geomoose".

There are a few things that need to be done to the cloned demo to make
it runnable:

1) Create a symlink so that the PHP directory is where apache expects it:

cd geomoose/js && ln -s ../services/php .

2) Compile the JavaScript. This is really an optimization step for
production.  "geomoose.html" is setup to use the JavaScript as
compressed by the dojo compiler.  The main benefit is far fewer files
need to be downloaded at page load.  "geomoose_dev.html" uses the source
files directly and is much easier to code/debug against.

cd libs && ./build_js.sh

3) Setup local_settings.ini so the PHP services know where things are.
Starting from unix_local_settings.ini in the geomoose/conf directory,
create local_settings.ini and adjust the paths to where the geomoose
files are on your computer.

cd ../.. # to get back to the top level geomoose directory
cd conf
cp unix_local_settings.ini local_settings.ini
nano local_settings.ini  # Or whatever your favorite editor is.

4) Tell Apache where to find the GeoMoose files.  It needs to see the js
directory under the top level geomoose directory.

For example, put something like this into your default site (Typically
"/etc/apache2/sites-available/default" on Debian/Ubuntu).  If you
installed the packages, MapServer will already be working in
'/cgi-bin/mapserv', and .php files should already be associated with PHP5.

<Directory /path/to/geomoose/js>
	Options Indexes FollowSymLinks MultiViews
	AllowOverride None
	Order allow,deny
	Allow from all
	DirectoryIndex index.html geomoose.html
</Directory>
Alias /geomoose/ /path/to/geomoose/js/


Remember to restart apache after making the changes so that the changes
take effect.

To build the natualdocs API documentation:

cd /path/to/geomoose/js
naturaldocs -i geomoose -o html apidocs -p ntdocs

To build the sphinx documentation:

The sphinx documentation lives in a separate git repository and needs to
be checked out with:

git clone https://github.com/geomoose/geomoose-docs.git

Then:

cd geomoose-docs
# Build the HTML version (results will be in build/html)
make html

# Build the PDF version (results will be in build/latex/GeoMOOSE.pdf)
make latex
cd build/latex
make all-pdf



More information about the Geomoose-users mailing list