0

I have an ember-cli app that uses ember simple auth(ember-simple-auth-devise) add on for authentication. I need to change the token end point of my authorizer to

http://example.com/api/v1/users/sign_in.

In my environment.js file I have added

ENV['simple-auth'] = {
        authorizer: 'simple-auth-authorizer:devise',
        crossOriginWhitelist: ['http://example.com'] //For CORS
    };

ENV['simple-auth-devise'] = {
      serverTokenEndPoint : 'http://example.com/api/vi/users/sign_in'
    }

But on logging in its still posts the credentials to the default url i.e. http://example1.com/users/sign_in.

How can I change this url to use my rails app endpoint.

ptwo
  • 461
  • 4
  • 13
  • are you running version 0.6.7 of the Ember CLI Addon and ran the generator (`ember g ember-cli-simple-auth-devise`) after updating? – marcoow Oct 07 '14 at 16:05
  • yes my version is 0.6.7 and i ran the generator. every thing is working fine its redirecting to my login route on authenticated routes just my end point is not configuring as expected – ptwo Oct 07 '14 at 16:53
  • What's your Ember CLI version? Please open an issue on github if you feel this is a bug. – marcoow Oct 13 '14 at 18:51

1 Answers1

2

Maybe the problem is that the property key is serverTokenEndpoint with a lowercase p. If you go to API docs you can see the correct property name.

franipfp
  • 160
  • 1
  • 9