-
Notifications
You must be signed in to change notification settings - Fork 3.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
admin API issues (solved) #42
Comments
I think there's an inconsistency between the docs and the actual implementation. I'll address those shortly and close this issue. |
Thanks @abiank for reporting this issue. The docs and implementation are in sync now. Please revisit the docs. All of you examples should work except the |
Http admin API docs use the "name" parameter, but the correct paramter to pass is "username"
i am having a few issues using the admin api. for example:
(influx is running on host y)
i add a db called testing
ale@cu:
$ curl -X POST 'http://y:8086/db?u=root&p=root' -d '{"name": "testing"}'$ curl -X POST 'http://y:8086/db/testing/admins?u=root&p=root' -d '{"username": "admin", "password": "whatever"}'the following line should add a db admin according to docs, but returns 404.
ale@cu:
404 page not found
another issue i have is that i cannot seem to add more than one user to a db:
ale@cu:~$ curl -X POST 'http://y:8086/db/testing/users?u=root&p=root' -d '{"name":"fulluser","password":"fulluser", "readPermissions":[{"matcher":"."}],"writePermissions":[{"matcher":"."}]}'
first added user is ok, but if i add another one:
ale@cu:~$ curl -X POST 'http://y:8086/db/testing/users?u=root&p=root' -d '{"name":"rouser","password":"rouser", "readPermissions":[{"matcher":".*"}],"writePermissions":[{"matcher":"null"}]}'
User already exists
it is telling me the user already exists even though names are different. and in the end if i do:
get a list of users for db testing
ale@cu:~$ curl 'http://y:8086/db/testing/users?u=root&p=root'
[{"username":""}]
...always an empty list, unless i use db site_dev, for which i get:
ale@cu:~$ curl 'http://y:8086/db/site_dev/users?u=root&p=daje'
[{"username":"al"},{"username":"public"}]
The text was updated successfully, but these errors were encountered: