A project to publish website analytics for the Municipality of Anchorage forked from analytics.usa.gov.
For a detailed description of how the site works, read 18F's blog post on analytics.usa.gov.
Other government agencies have reused analytics.usa.gov for their analytics dashboard. This blog post details their implementations and lessons learned.
Install [GNU Make for Windows] (http://gnuwin32.sourceforge.net/packages/make.htm) (optional)
Install Ruby using RubyInstaller for Windows.
Install [Bundler] (http://bundler.io)
gem install bundleThis app uses Jekyll to build the site, and Sass, Bourbon, and Neat for CSS. Install them all (from the directory containing the local copy of this github repository):
bundle installNOTE: The above items are not required for setup on a production server.
analytics-reporter is the code that powers the analytics dashboard.
Please clone the analytics-reporter next to a local copy of this github repository.
Some IIS versions will require the addition of the JSON and WOFF MIME types and most IIS versions will also require the addition of the WOFF2 MIME type.
| File Extension | MIME Type |
|---|---|
| .json | application/json |
| .woff | font/x-woff |
| .woff2 | font/woff2 |
See [analytics.usa.gov README.md] (https://github.com/18F/analytics.usa.gov/blob/18f-pages/README.md) for Linux setup instructions.
See [analytics.usa.gov README.md] (https://github.com/18F/analytics.usa.gov/blob/18f-pages/README.md) for agency setup instructions.
Development build using fake data:
make devThe development settings assume data is available at /fakedata. You can change this in _development.yml.
Test build using real data:
make testThis assumes you have already set up analytics-reporter in an adjacent directory.
Set an environment variable for the path to a file share on the production server:
export ANALYTICS_PROD_SHARE="\\prod_server\share"Production build that deploys to production share:
make deployIn production, the site's base URL is set to https://analytics.usa.gov and the data's base URL is set to https://analytics.usa.gov/data.
This project is in the worldwide public domain. As stated in CONTRIBUTING:
This project is in the public domain within the United States, and copyright and related rights in the work worldwide are waived through the CC0 1.0 Universal public domain dedication.
All contributions to this project will be released under the CC0 dedication. By submitting a pull request, you are agreeing to comply with this waiver of copyright interest.