Skip to content

Latest commit

 

History

History
43 lines (31 loc) · 1.56 KB

README.md

File metadata and controls

43 lines (31 loc) · 1.56 KB

riot-relay

A simple http proxy server to enable client calls to the Riot API using your own API key. CORS prevents us from querying the Riot API directly from a client -- this proxy fixes that. Not intended for large scale production use.

A barebones Node.js app using Express 4 and express-http-proxy.

Running Locally

Make sure you have Node.js and the Heroku CLI installed.

$ git clone https://github.com/prsauer/riot-relay.git # or clone your own fork
$ cd node-js-getting-started
$ export RIOT_API_KEY='<your riot key>'
$ npm install
$ npm start

Your app should now be running on localhost:5000.

Deploying to Heroku

$ heroku create
$ git push heroku master
$ Add RIOT_API_KEY as an config var with your Riot API key as the value 
$ heroku open

Optional: Add Redis Cache

You should simply need to provision the cache on Heroku and as long as the connection string is loaded to REDIS_URL on the Heroku config vars you are good to go.

$ Provision Redis cache on Heroku

More information