On Thursday, January 8, 2015 at 6:11:33 PM UTC-3, Traun Leyden wrote:
>
> I think you want to use admin_channels instead of channels, ie:
>
> curl -X PUT http://localhost:4985/adb/_user/fede --data \ '{"name": 
> "fede", "email":"[email protected] <javascript:>", "*admin_channels*":["*"], 
> "role":"user", "password": "******"}'
>

Thank you Jens, the was related to the access privileges because I have 
used a wrong attribute in the SG config file.
Thank you Traun, you were right, the problem was in the attribute name.

 

>
>
> On Thu, Jan 8, 2015 at 11:54 AM, Federico Hernandez <[email protected] 
> <javascript:>> wrote:
>
>>
>> On Thursday, January 8, 2015 4:51:08 PM UTC-3, Jens Alfke wrote:
>>>
>>> If you can see the docs in the _changes output on the admin interface, 
>>> but they don't replicate to the app, then the problem is probably with 
>>> access privileges. Make sure the user account the app logs in as has access 
>>> to at least one of the channels the docs are assigned to by the sync 
>>> function. 
>>>
>>
>> I'm using the following sync function:
>>
>> function (doc) {
>>   channel(doc.channels);
>> }
>>  
>> I created the user as following:
>>
>> curl -X PUT http://localhost:4985/adb/_user/fede --data \ '{"name": 
>> "fede", "email":"[email protected] <javascript:>", "channels":["*"], 
>> "role":"user", "password": "******"}'
>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"Couchbase Mobile" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/mobile-couchbase/f7eb7f28-0ec7-4a1d-9a62-4e4c7cafdae5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to