Project

General

Profile

Actions

action #157273

open

coordination #58184: [saga][epic][use case] full version control awareness within openQA

coordination #152847: [epic] version control awareness within openQA for test distributions

Run os-autoinst-distri-openQA directly from git without anything related in /var/lib/openqa/share/tests - Follow-up with ideas not tried out in the spike solution #157270 size:M

Added by okurz about 1 month ago. Updated 5 days ago.

Status:
Blocked
Priority:
Normal
Assignee:
Category:
Feature requests
Target version:
Start date:
2024-04-17
Due date:
% Done:

0%

Estimated time:

Description

Motivation

With #154783 we have proper git caching so we can run git based tests efficiently on our workers now. Now we should go the next step and migrate one "production" test distribution to use only git and not hold anything provided by admins on o3 in o3:/var/lib/openqa/share/tests for this test distribution.

Acceptance criteria

  • AC1: /var/lib/openqa/share/tests/open{qa,QA} do not exist
  • AC2: openqa-in-openqa tests still pass consistently
  • AC3: openqa-in-openqa test details, needle candidates and source code views still show content as expected

Suggestions

  • Change test definitions in https://github.com/os-autoinst/os-autoinst-distri-openQA/blob/master/scenario-definitions.yaml in your branch to use https://github.com/os-autoinst/os-autoinst-distri-openQA for test code (and needles)
  • Check that tests can be triggered this way on a test instance
  • Do not put anything in /var/lib/openqa/share/tests and ensure tests still work as well as source code view and needle candidates in test details pages
  • To provide needle candidates there are multiple possibilities when and where the needle candidate data can be provided, try out one or multiple of the following:
    1. Given a test distribution/needledir does not yet exist in a local cache (like asset downloads work or GIT_CACHE_DIR in os-autoinst and/or worker implementation), When tests are triggered on the side of web UI, Then the relevant data is git cloned, e.g. in the same steps as or similar to *_URL asset download
    2. Given a test distribution/needledir does not yet exist in a local cache, When the worker uploads the general test structure, e.g. which modules will be executed, Then the relevant data is git cloned
    3. Given a test distribution/needledir does not yet exist in a local cache, When the worker uploads individual needle check results, Then it also uploads as part of the JSON result files and image uploads all the necessary information to display needle candidates And the webUI in the receiving upload handler handles that somewhat … but does not overload when 1k workers upload in parallel or something :)
    4. Given a test distribution/needledir does not yet exist in a local cache, When the worker uploads final results (or "finalizes" the job), Then the webUI triggers a download of test files and/or needle files to a local git cache dir as necessary
    5. Given a test distribution/needledir does not yet exist in a local cache, When the first person reviews test results and selects needle candidates, Then the webUI triggers a download of test files and/or needle files to a local git cache dir as necessary
  • If you identify any bigger feature implementation in openQA or os-autoinst itself being necessary then ensure those requirements are covered in other tickets and block on those tickets accordingly

Out of scope

  • Any bigger feature implementation in openQA or os-autoinst itself.

Related issues 5 (3 open2 closed)

Related to openQA Project - action #158811: Add an automated way to install testsuite dependencies on the workerNew2024-04-10

Actions
Related to openQA Project - action #158826: openqa-in-openqa - test fails in start_test due to selecting the wrong base qcow image size:SResolveddheidler2024-04-11

Actions
Related to openQA Project - action #159171: Create and maintain up to date version of test distri/needles for webui size:MWorkable2024-04-17

Actions
Related to openQA Project - action #159174: Decrease load on remote git servers by not cloning CASEDIR/NEEDLE_DIR from every workerNewokurz2024-04-17

Actions
Copied from openQA Project - action #157270: [spike solution][timeboxed:20h] Run os-autoinst-distri-openQA directly from git without anything related in /var/lib/openqa/share/testsRejectedokurz2024-03-14

Actions
Actions #1

Updated by okurz about 1 month ago

  • Copied from action #157270: [spike solution][timeboxed:20h] Run os-autoinst-distri-openQA directly from git without anything related in /var/lib/openqa/share/tests added
Actions #2

Updated by okurz about 1 month ago

  • Target version changed from Tools - Next to Ready
Actions #3

Updated by okurz about 1 month ago

  • Subject changed from Run os-autoinst-distri-openQA directly from git without anything related in /var/lib/openqa/share/tests - Follow-up with ideas not tried out it spike solution #157270 to Run os-autoinst-distri-openQA directly from git without anything related in /var/lib/openqa/share/tests - Follow-up with ideas not tried out in the spike solution #157270 size:M
  • Description updated (diff)
  • Status changed from New to Workable
Actions #4

Updated by dheidler 25 days ago

  • Assignee set to dheidler
Actions #5

Updated by livdywan 24 days ago · Edited

Notes from the unblock:

Actions #6

Updated by dheidler 17 days ago

  • Status changed from Workable to In Progress
Actions #8

Updated by dheidler 17 days ago

  • Related to action #158811: Add an automated way to install testsuite dependencies on the worker added
Actions #9

Updated by dheidler 17 days ago

  • Status changed from In Progress to Feedback

After PR got merged, check that tests still work - then try removing openQA test distro folder from osd server.

Actions #10

Updated by tinita 16 days ago

  • Related to action #158826: openqa-in-openqa - test fails in start_test due to selecting the wrong base qcow image size:S added
Actions #11

Updated by tinita 16 days ago

I think this causes probblems, see #158826

Actions #12

Updated by dheidler 15 days ago

Fix for the cache issue in isotovideo: https://github.com/os-autoinst/os-autoinst/pull/2486

Actions #13

Updated by dheidler 11 days ago

  • Status changed from Feedback to Resolved
su _openqa-worker
_openqa-worker@openqaworker26:/root> cd /var/lib/openqa/cache/git/os-autoinst/os-autoinst-distri-openQA
_openqa-worker@openqaworker26:/var/lib/openqa/cache/git/os-autoinst/os-autoinst-distri-openQA> git fetch origin 7a0cc607f4481c66c3cac3b96e1cba90efa67b96
remote: Enumerating objects: 5, done.
remote: Counting objects: 100% (5/5), done.
remote: Compressing objects: 100% (2/2), done.
remote: Total 3 (delta 0), reused 3 (delta 0), pack-reused 0
Unpacking objects: 100% (3/3), 247 bytes | 247.00 KiB/s, done.
From https://github.com/os-autoinst/os-autoinst-distri-openQA
 * branch            7a0cc607f4481c66c3cac3b96e1cba90efa67b96 -> FETCH_HEAD
_openqa-worker@openqaworker26:/var/lib/openqa/cache/git/os-autoinst/os-autoinst-distri-openQA> git branch --force master FETCH_HEAD
[start new job]
_openqa-worker@openqaworker26:/var/lib/openqa/cache/git/os-autoinst/os-autoinst-distri-openQA> git log|cat
commit 9e2d1166307196db8ffc37064cc09a97b1cd8e33
Author: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Date:   Wed Apr 10 14:32:20 2024 +0000

    Merge pull request #171 from asdil12/casedir

    Set CASEDIR and NEEDLES_DIR to load testsuite from git

Cache update on master branch seems to work fine.

Actions #14

Updated by okurz 11 days ago

  • Due date set to 2024-04-22
  • Status changed from Resolved to Feedback
  • Priority changed from Normal to High

No, see our acceptance criteria

$ ssh o3-suse "ls -l /var/lib/openqa/share/tests | grep -i openqa"
drwxr-xr-x  7 geekotest nogroup  269 Apr 10 14:33 openqa
lrwxrwxrwx  1 root      root       6 Jan 16  2019 openQA -> openqa
Actions #15

Updated by dheidler 11 days ago

  • Status changed from Feedback to In Progress

I tried out how everything works without the folder present and it seems that the needle previews are not working like that.
I will ask Marius how https://github.com/os-autoinst/openQA/pull/5175 is supposed to work.
Also in the openQA code in lib/OpenQA/WebAPI/Controller/Step.pm in the src function we need to make adjustments so that the redirect to the webview of a git hosting platform doesn't only work for gitlab and gitub but for gitea, cgit, etc as well.
This could be done by adding a config entry to map a hostname of a git repo to the path - containing a wildcard for the branch name or ref.

Actions #16

Updated by dheidler 10 days ago

  • Subtask #159171 added
Actions #17

Updated by dheidler 10 days ago

  • Subtask #159174 added
Actions #18

Updated by dheidler 10 days ago

  • Status changed from In Progress to Blocked
Actions #19

Updated by okurz 9 days ago

  • Subtask deleted (#159171)
Actions #20

Updated by okurz 9 days ago

  • Subtask deleted (#159174)
Actions #21

Updated by okurz 9 days ago

  • Related to action #159171: Create and maintain up to date version of test distri/needles for webui size:M added
Actions #22

Updated by okurz 9 days ago

  • Related to action #159174: Decrease load on remote git servers by not cloning CASEDIR/NEEDLE_DIR from every worker added
Actions #23

Updated by okurz 9 days ago

I made those two new tickets siblings now.

Actions #24

Updated by dheidler 8 days ago

I don't know why you did that, but I would still consider this ticket blocked on #159171 and #159174

Actions #25

Updated by okurz 5 days ago

Yes, it's still blocked on #159171 and #159174. I didn't use the "blocked" relation because whenever we reconsider we wouldn't be able to close this ticket here without changing the ticket relation again so the best practice is to just add tickets as "related" and then mention that this is blocked on those, like you did now in #157273-24

Actions

Also available in: Atom PDF