We propose to implement the Rural Accessibility Hub using a static site generator like Metalsmith, and relies on Github to host the site and provide a content moderation workflow. This approach results in a website that doesn't need a backend, and is performant, secure and cost efficient to maintain.
Github is built and optimized to collaborate on code. The exact same workflows that teams use to review and approve code contributions, can be used to moderate content. Add the workflows that automatically publish the content to the live site, and we have a robust backend for the Rural Accessibility Hub that requires no further infrastructure.
Workflow
The general workflow with this approach is:
- A user that has run analysis in RAM chooses to export the project results to the Data Hub
- During export, the user provides additional information about the analysis
- The application automatically creates a GitHub Pull Request with this information
- The team that manages the RAH gets a notification and can accept or reject the Pull Request
1. Export results to RAH
After a user runs analysis for a scenario in RAM, they can choose to export the project results to the Data Hub.
2. Provide additional information
On export, the user provides additional information that will be used to provide context about the analysis on the Data Hub.
3. Create Pull Request
Using the information provided by the RAM user, the backend automatically creates a Pull Request in the repository for the Rural Accessibility Hub on Github. This Pull Request contains:
- a markdown file with the user provided content from the form
- the results of all the scenarios of the project in CSV and GeoJSON format
This Pull Request will generate a notification to all users on the RAH moderation team. The Pull Request message will also contain a quick link to Prose to make it easier for content moderators to edit the file.
4. Handle Pull Request
The moderation team can merge (accept) or close (reject) the Pull Request. If there is a need to make changes to the markdown file before merging the PR, they can do so through Prose.
When the PR is merged, Circle will build the site and push the new version live.