Quickstart Tutorials

Welcome! This page is a series of short tutorials to get Kebechet running on your repositories. The tutorials are in ascending complexity so we recommend starting with installing the GitHub app and then moving up from there based on your own personal use case.

GitHub Application

  1. To configure Kebechet, your repository should have a .thoth.yaml file in the root directory of the repository. Below you can find an example configuration file that has been annotated

    host: khemenu.thoth-station.ninja   # url of Thoth's user-api
    requirements_format: pipenv         # tool used for managing python package dependencies
    overlays_dir: overlays              # if your repository contains more than one runtime environment
    
    runtime_environments:
    - name: rhel-8                      # this will be used to find the environment specific files <overlay-dir>/<name>
      operating_system:
        name: rhel
        version: "8"
        python_version: "3.8"
        recommendation_type: latest     # if thoth-advise is being used this indicates priority for dependencies
    
    managers:
    - name: foo
      configuration:                    # manager specific configuration
        labels: [bot]
    
  2. Go to this link https://github.com/marketplace/khebhut

  3. Choose the repositories and orgs that you want to install Kebechet on

Congratulations! You have now installed Kebechet and it will actively manage your repositories. Kebechet’s behaviour is highly dependent on which managers you have installed we recommend familiarizing yourself with the managers you installed. This service is provided by the Thoth team at Red Hat.

Running Locally

Running Kebechet might interest you if you are a developer, someone looking to deploy Kebechet on their own, or if you are just curious.

  1. See step 1 of GitHub Application

  2. Setting up tokens and keys
    • SSH

      Here is a collection of links to documentation for associating an SSH key with your account on each platform.

    • Personal Access Token (OAuth)

      Here is collection of links to documentation on how to create OAuth tokens for each platform.

      • GitHub

      • GitLab

      • Pagure (this is the page to create your tokens on. No official documentation)

  3. Setting Environment Variables

    To interface with GitHub, GitLab, and Pagure you must set: GITHUB_KEBECHET_TOKEN, GITLAB_KEBECHET_TOKEN, and PAGURE_KEBECHET_TOKEN respectively. These are the “Personal Access Tokens” that you generated in the previous step.

    Beyond these there is no requirement for environment variables, however the CLI can be used by only setting environment variables. To see all of these values use the --help option when running the CLI.

  4. Running Kebechet
    $ pipenv run PYTHON_PATH=. kebechet-cli run-url -u <url-to-github-repo> -s <GITHUB|GITLAB|PAGURE>
    

    To get more information about the available commands run:

    $ pipenv run PYTHON_PATH=. kebechet-cli --help
    

    And to get more information about a specific command, including cli-options, run:

    $ pipenv run PYTHON_PATH=. kebechet-cli <command> --help
    

Deploying Kebechet

We release Kebechet images on quay.io. The entry point for the container is app.sh in the root directory of the Git repository.

Argo

Project Thoth uses Argo Workflows for our deployment of Kebechet. Here is a link to a basic workflow template to run Kebechet.

Todo

If you want to deploy Kebechet using different tooling please reachout if you need help or extend the documentation so others can benefit from your experience.