diff --git a/README.md b/README.md index 45f5e314c7..c74d95ad93 100644 --- a/README.md +++ b/README.md @@ -16,6 +16,29 @@ Known client implementations: - [unleash-client-node](https://github.com/unleash/unleash-client-node) - (you implementaiton here!) +# Running Unleash + +## Requirements + +You will need a __PostreSQL__ 9.3+ database instance to be able to run Unleash. + +When starting Unleash you must specify a database uri (can be set as environment variable DATABASE_URL) +which includes a username and password, that have rights to migrate the database. + +_Unleash_ will, at startup, check whether database migration is needed, and perform necessary migrations. + +## Start Unleash +### 1. The simplest way to get started: + +```bash +$ npm install unleash-server -g +$ unleash -d postgres://unleash_user:passord@localhost:5432/unleash -p 4242 + +Unleash started on port:4242 +``` + +You can also require Unleash as a lib and expend it with more options. Read more about this feature in the [getting started guide](./docs/getting-started.md). + ## Project details - [Project Roadmap](https://github.com/unleash/unleash/wiki/Roadmap) diff --git a/docs/developer-guide.md b/docs/developer-guide.md index 3efe1e7c4a..b8dd3d58ed 100644 --- a/docs/developer-guide.md +++ b/docs/developer-guide.md @@ -1,6 +1,6 @@ # Developer Guide -## Postgre +## PostgreSQL To run and develop unleash you need to have PostgreSQL databse (PostgreSQL v.9.5.x or newer) locally. diff --git a/docs/getting-started.md b/docs/getting-started.md index 83c7ce8d3b..f4251367dd 100644 --- a/docs/getting-started.md +++ b/docs/getting-started.md @@ -1,12 +1,15 @@ # Getting stated (v.1.0.x) -### Prerequisite -To run unleash you need to provide a PostgreSQL databse (PostgreSQL v.9.5.x or newer). +## Requirements -You need to give unleash a database uri which includes a username and password, that have rights to -migrate the database. _Unleash_ will, at startup, check whether database migration is needed, -and perform necessary migrations. +You will need a __PostreSQL__ 9.3+ database instance to be able to run Unleash. +When starting Unleash you must specify a database uri (can be set as environment variable DATABASE_URL) +which includes a username and password, that have rights to migrate the database. + +_Unleash_ will, at startup, check whether database migration is needed, and perform necessary migrations. + +## Start Unleash ### 1. The simplest way to get started: ```bash @@ -17,6 +20,7 @@ Unleash started on port:4242 ``` ### 2. Or programmatically: +You can also depend on unleash ```js const unleash = require('unleash-server'); @@ -28,3 +32,9 @@ unleash.start({ console.log(`Unleash started on port:${unleash.app.get('port')}`); }); ``` + +Available unleash options includes: + +- databaseURI +- port +- logLevel - ('INFO', 'ERROR',) \ No newline at end of file