This SOP covers the process of how to create a duffy tenant
ssh duffy.ci.centos.org
sudo su - duffy
<tenant name>: <API key>
duffy admin create-tenant <tenant name> <ssh pub-key>
ssh <host user>@<target host>
pip
pip3.8 install --user duffy[client]
.config
directory if it doesn’t exist and create .config/duffy
with the following contentclient: url: https://duffy.ci.centos.org/api/v1 auth: name: <tenant name> key: <API key>
duffy client list-pools
duffy client request-session pool=<name of the pool>,quantity=<number of sessions wanted>
By default this command outputs a json, but it's possible to change the format to yaml or flat using --format
. Under "node" key it's possible to find the hostname to be used. Log in to it as root
user, using ssh
.
{ ...output ommited... "nodes": [ { "hostname": "<hostname>.ci.centos.org", "ipaddr": "<ip address>", ...output ommited... }
duffy client retire-session <session id>
It's possible to check the session id either when the session is requested, in the output under "session" key, or using the following command:
duffy client list-sessions