NIH Wayfinding Tools (Prototype)
A combination of Vagrant 1.5+ and Ansible 1.8+ is used to setup the development environment for this project.
Before setting up the environment (and assuming you'd like OTP to build the graph its operations will range over), be sure that the following files are in deployment/ansible/roles/nih-wayfinding.otp-data/files/:
- OSM data extracts
- 'intersections' shapefile documents
- 'segments' shapefile documents
Once all files are where they need to be, use the following command to bring up a local development environment:
$ vagrant up
After provisioning is complete, you can login to the server:
$ vagrant ssh
Upon logging in, issue the following commands:
cd /opt/app
grunt serve
From there, you should be able to access the development server at: [http://localhost:8000/dev/]
The Vagrant configuration maps the following host ports to services
running in the VMs. You can change the host port numbers by setting
the environment variables listed in the Env Variable Override
column.
Service | Port | URL | Env Variable Override |
---|---|---|---|
Angular Web Application | 8000 | http://localhost:8000 | NIH_WAYFINDING_PORT_8000 |
PostgreSQL | 15432 | NIH_WAYFINDING_PORT_5432 | |
pgweb | 15433 | http://localhost:15433 | NIH_WAYFINDING_PORT_5433 |
livereload | 35729 | N/A |
TODO: add javascript/css instructions
In order to speed up things up, you may want to consider using a local caching proxy. The VAGRANT_PROXYCONF_ENDPOINT
environmental variable provides a way to supply a caching proxy endpoint for the virtual machines to use:
$ VAGRANT_PROXYCONF_ENDPOINT="http://192.168.96.10:8123/" vagrant up
TODO: add testing instructions
TODO: add deployment instructions
TODO: add dependency information