Closed karthik closed 10 years ago
I think it would also be better to store the auth key in an option rather than environment variable.
Thx-I'll update the example for auth
Should do_auth()
be run automatically? It's handy to be able to run it manually so you can troubleshoot your setup, but after that, why not run automatically?
I agree that it should run automatically when some other function requiring auth runs. Just like how Carl has now set it up with rfigshare.
True, authenticating automatically makes sense
Also if you store these in options make sure it's something less generic than api_key
and client_id
.
auth is already set up to happen automatically via do_get_auth()
which runs do_auth()
if id and key are not found
Auth issues
do_auth
. Good idea to add a package prefix to avoid namespace conflict but this is a pretty generic function name. I understand do stands for Digital Ocean. You might have to get creative here.do_auth
are outdated.The example for
?do_auth
says:This doesn't actually work because it still requires an inline key/secret to be pasted.