diff --git a/docs/operations/ci/adding_cico_tenant/adding-duffy-api-key.md b/docs/operations/ci/adding_cico_tenant/adding-duffy-api-key.md index 276f217..432d144 100644 --- a/docs/operations/ci/adding_cico_tenant/adding-duffy-api-key.md +++ b/docs/operations/ci/adding_cico_tenant/adding-duffy-api-key.md @@ -89,22 +89,13 @@ MariaDB [duffy]> ## Steps to create a new duffy API key -1. How do we connect to instances +1. The Duffy database runs on the admin.ci node: `ssh admin.ci.centos.org` and once in the admin node, login in mysql - duffy db -The Duffy database runs on the admin.ci node: `ssh admin.ci.centos.org`. +2. Create user in usertable `insert into users values(UUID(), 'projectname', 'projectname', NOW(), 5);` -2. We have a script which does this work.. how do we use it +3. Retrieve the api key from the users table ` select * from users where projectname="projectname";` Copy the API key somewhere handy (we will need it) -3. Create user in usertable -`insert into users values(UUID(), 'projectname', 'projectname', NOW(), 5);` - -4. Retrieve the api key from the users table -` select * from users where projectname="projectname";` -Copy the API key somewhere handy (we will need it) - -5. Using that api-key/UUID as project_id, enter ssh key of a user from the project so that they can ssh into the machines. This process must be repeated for every user we wish to add access to via SSH. -`insert into userkeys (`project_id`,`key`) values('', '');` -This ssh key is pushed to duffy nodes - authorized keys when a tenant requests the node through api key. +4. Using that api-key/UUID as project_id, enter ssh key of a user from the project so that they can ssh into the machines. This process must be repeated for every user we wish to add access to via SSH. `insert into userkeys (project_id,key) values(, );` This ssh key is pushed to duffy nodes - authorized keys when a tenant requests the node through api key. NOTE: we need to copy private key (pair of key just added in db), and paste it in openshift jenkins template (so copy it to save the trouble later)