Ask Your Question
0

Authentication gnocchi api is not working

asked 2018-04-27 14:19:51 -0500

updated 2018-04-30 08:39:41 -0500

I am developing an app which uses Gnocchi to collect some measures on OpenStack Pike. I intend to use the https://gnocchi.xyz/gnocchiclient/api.html#usage (gnocchi-api), but it is not clear how should I configure the environment to successfully authenticate. The code below is presented in the gnocchi-api docs and show how to authenticate using keystone.

from keystoneauth1 import loading
conf = cfg.ConfigOpts()
...
auth_plugin = loading.load_auth_from_conf_options(conf, "gnocchi_credentials")
gnocchi = client.Client(session_options={'auth': auth_plugin})

The problem come from the "conf" object: I have no info about what it is (a dictionary?), which data it carries and how to set proper auth info (username, password, project)... I appreciate any help on that!

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
1

answered 2018-04-29 20:54:00 -0500

It is an oslo-conf object. For example, see https://docs.openstack.org/keystoneau...

edit flag offensive delete link more

Comments

Thanks. Now, I can authenticate correctly :)

pablobrunetti gravatar imagepablobrunetti ( 2018-05-03 15:02:58 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower

Stats

Asked: 2018-04-27 14:19:51 -0500

Seen: 316 times

Last updated: Apr 30 '18