From 6ec6e84fd815a8a527274a702bc898cdcc3a2add Mon Sep 17 00:00:00 2001 From: Fabian Arrotin Date: Jul 29 2022 09:53:35 +0000 Subject: Adding ci duffy note and diagram Signed-off-by: Fabian Arrotin --- diff --git a/docs/ci.md b/docs/ci.md index dd224db..1da4e12 100644 --- a/docs/ci.md +++ b/docs/ci.md @@ -3,6 +3,11 @@ The CentOS Project has some resources available for each SIG to run some CI jobs/tests for their projects. We'll document soon how to get onboarded (on request) on the CentOS CI infra platform. +![CI Infra overview](img/duffy-aws.drawio.png) + +!!! warning + This is the future plan as we're currently moving infra from local DC to AWS. + We offer the following resources : * Openshift hosted jenkins (one per project/SIG), using usual authentication from FAS/ACO @@ -37,7 +42,7 @@ That environment pod is using a centos 8-stream based container, that will autom * python-cicoclient (for legacy Duffy, see below) * duffy[client] pip package (to interact with newer Duffy, see below) -That pod will mount the ssh private key used for your project under /duffy-ssh-key/ssh-privatekey (see [ssh_config](https://github.com/centosci/images/blob/master/cico-workspace/ssh_config#L2)) and also have the `CICO_API_KEY` env variable set up to request duffy v2 nodes (through cico client) +That pod will mount the ssh private key used for your project under /duffy-ssh-key/ssh-privatekey (see [ssh_config](https://github.com/centosci/images/blob/master/cico-workspace/ssh_config#L2)) and also have the `CICO_API_KEY` env variable set up to request duffy v2 nodes From that point, it's up to you to : @@ -69,7 +74,7 @@ To be able to request ephemeral nodes to run your tests, you'll need both your ` ### Installing and configuring duffy client -Use `pip` (or `pip3.8` on el8) to install duffy client. +Use `pip` (or `pip3.8` on el8) to install duffy client. (already installed in `cico-workspace` pod template in openshift so not needed there) ```shell pip install --user duffy[client] @@ -85,7 +90,17 @@ client: key: ``` +One can also call `duffy client` without any existing config file (if you want to): + +``` +duffy client --url https://duffy.ci.centos.org/api/v1 --auth-name --auth-key $CICO_API_KEY +``` + +!!! danger + never leak your API key so if you use this command from within jenkins, by default jenkins is using `set -x` so outputing/echoing commands. So don't forget to use `set +x` before the duffy call (or else). + ### Requesting a session + Before creating a session, the name of the pool is required. Check the pool available executing the command. ```shell diff --git a/docs/img/duffy-aws.drawio.png b/docs/img/duffy-aws.drawio.png new file mode 100644 index 0000000..262f202 Binary files /dev/null and b/docs/img/duffy-aws.drawio.png differ