Differences

This shows you the differences between two versions of the page.

Link to this comparison view

infrastructure:oldwiki [2016/03/15 02:43]
infrastructure:oldwiki [2016/03/15 02:43] (current)
Line 1: Line 1:
 +===== Summary =====
  
 +The HSBNE Wiki is a [[https://​github.com/​gollum/​gollum|Gollum]] instance running on a [[http://​rack.github.io/​|Rack]],​ [[https://​www.phusionpassenger.com/​|Passenger]],​ [[http://​nginx.org/​en/​|Nginx]],​ [[http://​www.ubuntu.com/​|Ubuntu 12.04 Linux]] stack deployed to a [[http://​digitalocean.com/​|DigitalOcean Droplet]] via [[http://​www.ansibleworks.com/​|Ansible]]. Phew, what a mouthful!
 +
 +===== Hosts =====
 +
 +wiki.hsbne.org is a vhost for do1.hsbne.org
 +
 +===== Repositories =====
 +
 +  * Gollum Application https://​github.com/​HSBNE/​Wiki-GollumRack
 +  * Server Deployment https://​github.com/​HSBNE/​DigitalOcean01
 +
 +===== Implementation Notes =====
 +
 +The Gollum rack application pulls in the [[https://​github.com/​arr2036/​omnigollum/​|OmniGollum]] plugin, which is a wrapper for [[https://​github.com/​intridea/​omniauth|OmniAuth]]. This allows us to enforce logins using openid systems. Currently, it supports [[https://​github.com/​zquestz/​omniauth-google-oauth2|Google Oauth2]]. [[https://​github.com/​intridea/​omniauth/​wiki/​List-of-Strategies|Alternate providers]] are available.
 +
 +All editing/​creation methods are behind the login system.
 +
 +The ''​%%/​members/​%%''​ path is also behind the login system, this enforces an area only available to logged in accounts. There'​s no way to control those accounts on the application side short of managing a whitelist. You can, however, use google apps auth which we could restrict to @hsbne.org accounts.
 +
 +We modify the template path (since mustache annoyingly doesn'​t support multiple paths) to not utilise the gollum gem templates. This gives us control over look and feel (see the logged in status widget top right) but means an increased maintenance load as gollum updates. The app also monkey patches some views to make that widget work, rather than maintain our own version of gollum downstream.
 +
 +Livepreview is disabled, as it lacks a toolbar for editing, and most users find the new interface (and rightly so) disconcerting.
 +
 +===== Contributing =====
 +
 +Like the [[http://​wiki.hsbne.org/​Infrastructure/​Infrastructure/​Forum|Forum]],​ the Wiki is developed utilising [[http://​vagrantup.com|Vagrant]]. You can clone the Gollum Application and create your own testable instance by running ''​%%vagrant up%%''​
 +
 +When you make changes, you can restart the application by using ''​%%touch tmp/​restart.txt%%''​
 +
 +If you change gems or something to do with bundler, you can uncomment the ''​%%ansible.tags%%''​ line in ''​%%Vagrantfile%%''​ and run ''​%%vagrant provision%%''​ which will rebuild the application including all gems etc.
 +
 +  - Fork and Clone the Repo
 +  - Make your changes
 +  - Test changes utilising vagrant
 +  - Once happy, commit and push
 +  - Create a pull request detailing the change
 +
 +Extra points if you also update the Server Deployment repo if you require deployment changes (such as new packages)