It'd be nice if cmk could read this stuff from env vars, but alas it doesn't seem to be the case. Ask for a feature. :)

Otherwise, what you can do is set stuff up temporarily then delete it when done, for example:
(let's use a non-default config path, so it's extra disposable)

cmkconfig=$(mktemp -p .)
cmk -c "$cmkconfig" set url cloud:8080/client/api
cmk -c "$cmkconfig" set apikey lalala
cmk -c "$cmkconfig" set secretkey skeylalala

Then do you stuff with cmk:
cmk -c "$cmkconfig" list virtualmachines etc

And when you are done just delete the file:
rm -f "$cmkconfig"

HTH

On 2023-04-06 13:57, jordan j wrote:
Do you know if it is possible and what is the syntax to use cloudmonkey
commands without configuring profile? I dont want to have credentials or
keys on the server disk.

Is it possible to do something like this?

cmk list instances -key my_key -secret my_secret

I see no such arguments in the documentation.

Regards,
Jordan

Reply via email to