## action #2214

action #2396: Refactor job_templates and friends

### Better management of ENV variables on job_templates

Status:
Resolved
Priority:
Urgent
Assignee:
Category:
-
Target version:
Start date:
2014-04-03
Due date:
% Done:

50%

Estimated time:
30.00 h
Difficulty:

Description

Right now, products, machines and test_suites can define environment variables. But those list of variables are only a string that is parsed. That can be improved in several ways:

• We need to be careful about what we accept as variable names in the web ui. Since those settings are exported to the environment things like e.g LD_PRELOAD must not be allowed. Maybe we should rename all variables to start with OPENQA_ or something similar to avoid side effects in the first place.
• Create the key / value separation of variables, as was done in job_settings table
• Drive / limit / control the options that the user have in the UI side (DESKTOP \in {KDE, GNOME, XFCE, LXDE})

We have to decide where we want to go exactly and then implement it.

Related issues

Related to openQA Project - action #2434: get rid of environment variablesResolved2014-05-05

Related to openQA Project - action #2524: [webui] better display of test suite variable settingsNew2014-05-19

### History

#### #1 Updated by lnusselover 8 years ago

wrt to meta data declaration in os-autoinst I'd go for something similar to what we use in sysconfig, see /usr/share/doc/packages/yast2-sysconfig/metadata.txt:

       Supported types:

Type                        Valid values
---------------------------------------------------------------------
string              any value
string(v1,v2,...)   value from list or any value
list(v1,v2,...)     only value from list
integer             integer
integer(min:max)    integer in specified range (one limit can be missing,
use e.g. integer(0:) for values >= 0)
boolean             only "true" or "false"
yesno               only "yes" or "no"
ip                  IPv4 or IPv6 adress (e.g. 10.20.0.1)
regexp(re)          only strings that matches regular expression re
(POSIX Extended Regular Expression), e.g. use
regexp(^0[0-7]*\$) for octal values.

If this keyword is missing default value "string" will be used.


#### #2 Updated by ancorgsover 8 years ago

• Parent task set to #2396

#### #3 Updated by ancorgsover 8 years ago

• Target version set to Sprint 07

#### #4 Updated by lnusselover 8 years ago

• Status changed from New to In Progress
• Assignee set to lnussel

as per discussion in the startup meeting we will limit this to a minimal implementation for now

#### #5 Updated by lnusselover 8 years ago

• % Done changed from 0 to 30

#### #6 Updated by lnusselover 8 years ago

• % Done changed from 30 to 40

#### #7 Updated by lnusselover 8 years ago

• % Done changed from 40 to 50

variable split done

#### #8 Updated by lnusselover 8 years ago

• Status changed from In Progress to Resolved

closing, see #2524 for follow-up

Also available in: Atom PDF