Skip to content

Commit

Permalink
Merge pull request #126 from conveyal/dev
Browse files Browse the repository at this point in the history
v3.0.0
  • Loading branch information
trevorgerhardt committed Mar 5, 2019
2 parents d4c3508 + d37fada commit ecf7d39
Show file tree
Hide file tree
Showing 137 changed files with 6,046 additions and 17,089 deletions.
14 changes: 0 additions & 14 deletions .flowconfig

This file was deleted.

7 changes: 3 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
*.swp
.env
.next
node_modules
npm-debug.log
assets
configurations/*
!configurations/default
!configurations/messages
tmp
config.json
yarn-error.log
store.json
10 changes: 3 additions & 7 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,16 +1,12 @@
sudo: false
language: node_js
cache:
yarn: true
notifications:
email: false
node_js:
- '8'
before_install:
- yarn global add codecov
- '10'
scripts:
- yarn test -- --coverage --coverage-paths src/**/*.js
- codecov
- yarn run check-format
- yarn test
- yarn run build
after_success:
- yarn run semantic-release
Expand Down
22 changes: 10 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,25 +7,23 @@

## Running

Clone the repository and with [yarn](https://yarnpkg.com/en/) and [node v8](https://nodejs.org/en/) installed run `yarn start`. Changes to JavaScript and CSS will be rebuilt automatically. Refresh your web page to see changes. Changes to configuration files require a full stop and fresh `yarn start`.
Clone the repository and with [yarn](https://yarnpkg.com/en/) and [node v10](https://nodejs.org/en/) installed run `yarn run dev`. Taui is built and run with [next.js](https://nextjs.org) and [now](https://now.js).

## Configuration

Taui allows changing it's source data live by default. It's set via JSON and an example can be found in `config.json.tmp`. Opportunities can be set in the `grids` field and transit networks generated by an r5 regional analysis can be set in networks.
Copy the `empty-store.json` file to `store.json`. This file populates the data used for running a Taui.

For permanent deployments, set `DISABLE_CONFIG: true` in the `env.yml` file and set the configuration data in `store.yml` under the `data` field.
**Key fields:**

## Deploy
* `allowChangeConfig` -- Set to `false` when deploying a site for a user.
* `map.accessToken` -- A [Mapbox](https://mapbox.com) access token is required for Mapbox GL maps and Mapbox Geocoding to work.
* `grids` -- Point sets or opportunities can be set here.
* `networks` -- A url to an S3 bucket containing the results of regional analysis generated from R5.
* `poiUrl` -- URL to a GeoJSON file that contains a `FeatureCollection` of `Points` to be shown on the map. Add a `label` to the `properties` field of each point.

Once you see that TAUI is working properly with your static site data, deploy it to the S3 bucket specified in settings.yml with the following command (replacing the --config switch to point to your configuration directory):
## Deployment

`mastarm deploy --config configurations/marseilles --minify --env production`

The AWS SDK for JS will detect and use the same AWS credentials you should have set up for AWSCLI. The deployment copies JS and CSS files into a sub-bucket called assets, but does not upload `index.html`. You need to edit `index.html` in the root of the TAUI repository to customize the page name, then upload it with `aws s3 cp index.html s3://your-bucket-name/index.html`.

`mastarm deploy` will not create the bucket or set its contents public. You need to ensure the bucket exists before running `mastarm deploy` and set all its contents public afterward using the S3 web console or CLI. You don’t need to set any permissions on the bucket itself.

If S3 reports “access denied” when you try to fetch a page over HTTP in your browser, this is often because an object you are requesting does not exist.
[![Deploy to now](https://deploy.now.sh/static/button.svg)](https://deploy.now.sh/?repo=https://github.com/conveyal/taui)

[npm-image]: https://img.shields.io/npm/v/@conveyal/taui.svg?maxAge=2592000&style=flat-square
[npm-url]: https://www.npmjs.com/package/@conveyal/taui
Expand Down
176 changes: 0 additions & 176 deletions __mocks__/leaflet.js

This file was deleted.

7 changes: 0 additions & 7 deletions __mocks__/react-leaflet.js

This file was deleted.

15 changes: 0 additions & 15 deletions config.json.tmp

This file was deleted.

1 change: 0 additions & 1 deletion configurations/default/.gitignore

This file was deleted.

5 changes: 0 additions & 5 deletions configurations/default/env.yml.tmp

This file was deleted.

39 changes: 0 additions & 39 deletions configurations/default/messages.yml

This file was deleted.

7 changes: 0 additions & 7 deletions configurations/default/settings.yml

This file was deleted.

14 changes: 0 additions & 14 deletions configurations/default/store.yml

This file was deleted.

12 changes: 0 additions & 12 deletions configurations/messages/messages-fr.yml

This file was deleted.

7 changes: 0 additions & 7 deletions configurations/test/env.yml

This file was deleted.

Loading

0 comments on commit ecf7d39

Please sign in to comment.