No description, website, or topics provided.
HTML JavaScript ApacheConf CSS
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
build
docs
public
server
.DS_Store
.gitattributes
.gitignore
README.md
app.js
build.sh
error.log
package.json

README.md

HSTRNY website

Requires

  • Node / NPM
  • Yeoman

Install:

  • Clone the repos
  • git clone https://github.com/Tidwell/hearth-angular.git
  • git clone https://github.com/Tidwell/node-challonge
  • Link node-challonge for hearth-angular
  • cd node-challonge; npm link;
  • cd ../; cd hearth-angular
  • npm link challonge
  • Install hearth-angular
  • npm install
  • Create config
  • mkdir server/config
  • vi server/config/local.js
module.exports = {
  env: 'local',
  server: {
    port: 8080
  },
  angularServer: {
    staticDirectory: '/public/app',
    uriPath: '/'
  },
  socket: {
    log: false
  },
  tournaments: {
    key: 'YOUR CHALLONGE API KEY HERE',
    subdomain: 'HSTRNY',
    regions: ['NA', 'EU'],
    regionPrefix: '[',
    regionSuffix: ']',
    namePrefix: '8 Player Tournament ',
    dropTimeout: 60000
  },
  db: 'mongodb://localhost/hearth-angular'
};

Build:

  • ./build.sh in ./

Run:

  • node app in ./

View: http://localhost:8080

##CLI Arguments

--env (-e) config file to load.

  node app --env=prod //run with the config from ./app/config/prod.js

##Deploy

  • ./build.sh
  • git subtree push --prefix build origin live2
  • ssh into box
  • git pull

If server needs restart:

  • OLD

  • Look for the process on port 9007 using: netstat -tulpn

  • kill #PID

  • nohup node app -env=prod &

  • sudo service apache2 restart

  • NEW

  • Use forever start app.js -env=prod &

  • sudo service apache2 restart

Bug Tracking: