peterhughesdev / pvteam

PVTeam website

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

##PVTEAM website

###Running the site A startup script, pvteam.sh, is provided that will handle the starting of Mongo and the running of the site in production mode. It assumes that 'forever' has been installed as a global NPM dependency (npm install -g forever)

By default the server will listen on port 3000. It is expected that a proxy (i.e Nginx) will handle the passing of connections from port 80.

###Installation If you're reading this then I assume you've already cloned the source project. If not, install git and then git clone from the github repository.

You will need Mongo & Node installed.

To download and install website dependencies, cd to the folder containing this readme, and then run 'npm install'. You are now good to go!

###Application details

The website is built using Keystone, a NodeJS site framework. The directory structure is the same as that used by Express (a NodeJS library used internally by Keystone)

Global app configuration is handled within keystone.js. See the Keystone documentation for details.

Page templates are stored under the /templates dir. They use Handlebars for the templating language.

URL routing, and the middleware controllers used, are found within the /routes dir. The Keystone data model has been setup such that there is a generic 'page' type - this can be used for adding textual content with a default template directly from the admin interface, without needing to edit the routes. Specialised pages, such as news or members pages, have their own templates and controllers.

The CSS is written using SASS, with the files found under /public/styles/site/ - do not edit the site.css or site.scss files directly, as these are auto-generated by Keystone when it starts.

Required images and client-side js files are found within /public. This is the only directly that will serve user requested files. Images that have been uploaded can be found within /public/images/uploads

Data models for the application are defined within the /models dir. These map onto the editable features within the Keystone admin, and are stored within the mongo database.

About

PVTeam website


Languages

Language:JavaScript 86.9%Language:Handlebars 9.4%Language:CSS 3.3%Language:Shell 0.4%