Vagrant

From GRASS-Wiki
Revision as of 16:46, 7 February 2016 by ⚠️Landa (talk | contribs) (→‎Usage)
Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

This page shows how to use Vagrant together with GRASS GIS. The GRASS source code contains customized Vagrantfile. This highly simplifies the vagrant usage.

Note: '$' shows commands to be entered from local machine, '#' from vagrant's virtual machine

First of all we download GRASS source code from SVN:

$ svn checkout https://svn.osgeo.org/grass/grass/trunk grass_trunk

We start new vagrant instance by:

$ vagrant up

The command creates new vagrant virtual machines, downloads all dependecies, and compiles GRASS on this machine. You can connect to this machine by:

$ vagrant ssh

Enjoy!

Usage

The common usage may be:

1) create 'grassdata' directory in vagrant's home directory (enter commands from virtual machine):

# mkdir grassdata && cd grassdata

2) download sample data

# wget https://grass.osgeo.org/sampledata/north_carolina/nc_spm_08_grass7.tar.gz
# tar xzf nc_spm_08_grass7.tar.gz

Note: you can also copy your local data to the virtual machine by 'scp' command (enter commands from your local machine):

$ vagrant ssh-config > ssh-config
$ scp -r -F ssh-config /opt/grassdata/gismentors grass-gis-vagrant:grassdata

3) start GRASS from virtual machine

# grass71

To halt running virtual machine type:

vagrant halt

How to update GRASS installation