[ckan-dev] [lists.okfn.org] Authorization problem with the DataStore

Anes MAHI anes.mahi at edf.fr
Mon May 4 11:57:30 UTC 2015


Dear CKAN developers,

I am beginner in CKAN and I have problems when trynig to create resources 
using upload files. I've got the following error message:

[Errno 13] Permission denied : '/var/lib/ckan/resource/xyz'  where xyz is 
a random string generated each time I try to upload a file. So I can't 
create the folder and give it the permission.

Also my datastore is empty and when I try to create a resource using 
command ligne : 

curl -X POST http://127.0.0.1:5000/api/3/action/datastore_create
         -H "Authorization: {MY API KEY}"
         -d '{"resource": {"package_id": "{PACKAGE ID OF EXISTING 
DATASET}"}, 
                "fields": [ {"id": "a"}, {"id": "b"} ], 
                "records": [ { "a": 1, "b": "xyz"}, {"a": 2, "b": "zzz"} 
]}'

I have this error message 

{"help": "
http://127.0.0.1:5000/api/3/action/help_show?name=datastore_create", 
        "success": false,
         "error": {"message": "Access denied: <function datastore_create 
at 0x41c5668> requires an authenticated user",
                 "__type": "Authorization Error"}}

Do you have any ideas ? I need your help please.

Thank you for your time.

Best regards 

Anès



Ce message et toutes les pièces jointes (ci-après le 'Message') sont établis à l'intention exclusive des destinataires et les informations qui y figurent sont strictement confidentielles. Toute utilisation de ce Message non conforme à sa destination, toute diffusion ou toute publication totale ou partielle, est interdite sauf autorisation expresse.

Si vous n'êtes pas le destinataire de ce Message, il vous est interdit de le copier, de le faire suivre, de le divulguer ou d'en utiliser tout ou partie. Si vous avez reçu ce Message par erreur, merci de le supprimer de votre système, ainsi que toutes ses copies, et de n'en garder aucune trace sur quelque support que ce soit. Nous vous remercions également d'en avertir immédiatement l'expéditeur par retour du message.

Il est impossible de garantir que les communications par messagerie électronique arrivent en temps utile, sont sécurisées ou dénuées de toute erreur ou virus.
____________________________________________________

This message and any attachments (the 'Message') are intended solely for the addressees. The information contained in this Message is confidential. Any use of information contained in this Message not in accord with its purpose, any dissemination or disclosure, either whole or partial, is prohibited except formal approval.

If you are not the addressee, you may not copy, forward, disclose or use any part of it. If you have received this message in error, please delete it and all copies from your system and notify the sender immediately by return message.

E-mail communication cannot be guaranteed to be timely secure, error or virus-free.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.okfn.org/pipermail/ckan-dev/attachments/20150504/7253dbc4/attachment-0002.html>


More information about the ckan-dev mailing list