Instructions on how to build/run your application
Pre-requisites:
- Latest version of redis and docker needs to be installed
Run the following commands in your terminal:
- 'cd /path/to/task_app'
- 'rvm gemset create task_app'
- 'rvm gemset use task_app'
- 'rvm gemset list' to verify (optional)
- 'bundle install'
- 'yarn install --check-files'
- redis-server
- Running test-cases:
- 'bundle exec rspec --format documentation'
- Starting the application
- docker-compose up --build
- To create user send request in the following format:
- 'post '/api/users/create', params: { 'user': {'username': 'test', 'password': '1234578'} }, headers: { 'Content-Type': 'application/json', 'HTTP_API_KEY': 'f294440ff51973cc255e908b8dac234a931c8494' }'
- To login user send request in the following format:
- 'post "/api/users/login", params: { 'user': { 'username': 'test', 'password': '1234578' } }, headers: { 'Content-Type': 'application/json', 'HTTP_API_KEY': 'f294440ff51973cc255e908b8dac234a931c8494' }''
- Use the jwt response token from the two api responses for future requests.