/teuthology-api

A REST API to execute teuthology commands.

Primary LanguagePython

Teuthology API

A REST API to execute teuthology commands.

Setup

Option 1: (teuthology docker setup)

  1. Clone teuthology and teuthology-api.
  2. Add the following to teuthology's docker-compose services.
    teuthology_api:
        build:
          context: ../../../teuthology-api
        ports:
            - 8082:8082
        depends_on:
            - teuthology
            - paddles
        links:
            - teuthology
            - paddles
    
  3. Follow teuthology development setup instructions from here.

Documentation

The documentation can be accessed at http://localhost:8082/docs after running the application.

Route /

curl http://localhost:8082/

Returns {"root": "success"}.

Route /suite

POST /suite/: schedules a run. Example:

curl --location --request POST 'http://localhost:8082/suite/' \
--header 'Content-Type: application/json' \
--data-raw '{
         "--ceph": "wip-dis-testing-2",
         "--ceph-repo": "https://github.com/ceph/ceph-ci.git",
         "--kernel": "distro",
         "--limit": "2",
         "--newest": "0",
         "--machine-type": "testnode",
         "--num": "1",
         "--priority": "70",
         "--suite": "teuthology:no-ceph",
         "--suite-branch": "wip-dis-testing-2",
         "--suite-repo": "https://github.com/ceph/ceph-ci.git",
         "--teuthology-branch": "main",
         "--verbose": "1",
         "--user": "vallariag"
 }'