Bug 1197608

Summary: bkr workflow-kernel won't filter the task about arch requre if the tasks are specified with --taskifle='mytaskfile'
Product: [Retired] Beaker Reporter: Chunyu Hu <chuhu>
Component: command lineAssignee: Roman Joost <rjoost>
Status: CLOSED CURRENTRELEASE QA Contact: tools-bugs <tools-bugs>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 19CC: bpeck, chuhu, dcallagh, dowang, ebaak, jburke, jstancek, rjoost
Target Milestone: 23.2Keywords: Patch
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-09-02 07:01:25 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Chunyu Hu 2015-03-02 08:14:37 UTC
Description of problem:


Version-Release number of selected component (if applicable):

beaker-client-19.2-1.el7eng.noarch

How reproducible:

Always

Steps to Reproduce:

[root@dhcp-13-17 taskfiles]# rpm -q beaker-client
beaker-client-19.2-1.el7eng.noarch
[root@dhcp-13-17 taskfiles]# cat securety.list 
/kernel/security/execshield/protection
[root@dhcp-13-17 taskfiles]# cat /home/hcy/kernel/security/execshield/protection/Makefile  |grep arch
[root@dhcp-13-17 taskfiles]# cat /home/hcy/kernel/security/execshield/protection/Makefile  |grep -i arch
	@echo "Architectures:   i386"		>> $(METADATA)
[root@dhcp-13-17 taskfiles]# bkr workflow-kernel --taskfile=securety.list --arch=s390x --dryrun --distro=RHEL-6.5 --prettyxml    --nvr=2.6.32-431.50.1.el6  
<job retention_tag="Scratch">
	<whiteboard>2.6.32-431.50.1.el6 None</whiteboard>
	<recipeSet>
		<recipe ks_meta="method=nfs" whiteboard="2.6.32-431.50.1.el6">
			<distroRequires>
				<and>
					<distro_name op="=" value="RHEL-6.5"/>
					<distro_variant op="=" value="Server"/>
					<distro_arch op="=" value="s390x"/>
				</and>
			</distroRequires>
			<hostRequires/>
			<repos/>
			<partitions/>
			<task name="/distribution/install" role="STANDALONE">
				<params/>
			</task>
			<task name="/distribution/kernelinstall" role="STANDALONE">
				<params>
					<param name="KERNELARGVARIANT" value="up"/>
					<param name="KERNELARGNAME" value="kernel"/>
					<param name="KERNELARGVERSION" value="2.6.32-431.50.1.el6"/>
				</params>
			</task>
			<autopick random="true"/>
			<task name="/kernel/security/execshield/protection" role="STANDALONE">
				<params/>
			</task>
		</recipe>
	</recipeSet>
	<recipeSet>
		<recipe ks_meta="method=nfs" whiteboard="2.6.32-431.50.1.el6">
			<distroRequires>
				<and>
					<distro_name op="=" value="RHEL-6.5"/>
					<distro_variant op="=" value="Server"/>
					<distro_arch op="=" value="s390x"/>
				</and>
			</distroRequires>
			<hostRequires/>
			<repos/>
			<partitions/>
			<task name="/distribution/install" role="STANDALONE">
				<params/>
			</task>
			<task name="/distribution/kernelinstall" role="STANDALONE">
				<params>
					<param name="KERNELARGVARIANT" value="up"/>
					<param name="KERNELARGNAME" value="kernel"/>
					<param name="KERNELARGVERSION" value="2.6.32-431.50.1.el6"/>
				</params>
			</task>
			<autopick random="true"/>
			<task name="/kernel/security/execshield/protection" role="STANDALONE">
				<params/>
			</task>
		</recipe>
	</recipeSet>
	<recipeSet>
		<recipe ks_meta="method=nfs" whiteboard="2.6.32-431.50.1.el6 debug">
			<distroRequires>
				<and>
					<distro_name op="=" value="RHEL-6.5"/>
					<distro_variant op="=" value="Server"/>
					<distro_arch op="=" value="s390x"/>
				</and>
			</distroRequires>
			<hostRequires/>
			<repos/>
			<partitions/>
			<task name="/distribution/install" role="STANDALONE">
				<params/>
			</task>
			<task name="/distribution/kernelinstall" role="STANDALONE">
				<params>
					<param name="KERNELARGVARIANT" value="debug"/>
					<param name="KERNELARGNAME" value="kernel"/>
					<param name="KERNELARGVERSION" value="2.6.32-431.50.1.el6"/>
				</params>
			</task>
			<autopick random="true"/>
			<task name="/kernel/security/execshield/protection" role="STANDALONE">
				<params/>
			</task>
		</recipe>
	</recipeSet>
</job>

[root@dhcp-13-17 taskfiles]# bkr workflow-kernel --task=/kernel/security/execshield/protection  --dryrun --distro=RHEL-6.5 --prettyxml    --nvr=2.6.32-431.50.1.el6  --arch=s390x<job retention_tag="Scratch">
	<whiteboard>2.6.32-431.50.1.el6 None</whiteboard>
	<recipeSet>
		<recipe ks_meta="method=nfs" whiteboard="2.6.32-431.50.1.el6">
			<distroRequires>
				<and>
					<distro_name op="=" value="RHEL-6.5"/>
					<distro_variant op="=" value="Server"/>
					<distro_arch op="=" value="s390x"/>
				</and>
			</distroRequires>
			<hostRequires/>
			<repos/>
			<partitions/>
			<task name="/distribution/install" role="STANDALONE">
				<params/>
			</task>
			<task name="/distribution/kernelinstall" role="STANDALONE">
				<params>
					<param name="KERNELARGVARIANT" value="up"/>
					<param name="KERNELARGNAME" value="kernel"/>
					<param name="KERNELARGVERSION" value="2.6.32-431.50.1.el6"/>
				</params>
			</task>
			<autopick random="true"/>
		</recipe>
	</recipeSet>
	<recipeSet>
		<recipe ks_meta="method=nfs" whiteboard="2.6.32-431.50.1.el6">
			<distroRequires>
				<and>
					<distro_name op="=" value="RHEL-6.5"/>
					<distro_variant op="=" value="Server"/>
					<distro_arch op="=" value="s390x"/>
				</and>
			</distroRequires>
			<hostRequires/>
			<repos/>
			<partitions/>
			<task name="/distribution/install" role="STANDALONE">
				<params/>
			</task>
			<task name="/distribution/kernelinstall" role="STANDALONE">
				<params>
					<param name="KERNELARGVARIANT" value="up"/>
					<param name="KERNELARGNAME" value="kernel"/>
					<param name="KERNELARGVERSION" value="2.6.32-431.50.1.el6"/>
				</params>
			</task>
			<autopick random="true"/>
		</recipe>
	</recipeSet>
	<recipeSet>
		<recipe ks_meta="method=nfs" whiteboard="2.6.32-431.50.1.el6 debug">
			<distroRequires>
				<and>
					<distro_name op="=" value="RHEL-6.5"/>
					<distro_variant op="=" value="Server"/>
					<distro_arch op="=" value="s390x"/>
				</and>
			</distroRequires>
			<hostRequires/>
			<repos/>
			<partitions/>
			<task name="/distribution/install" role="STANDALONE">
				<params/>
			</task>
			<task name="/distribution/kernelinstall" role="STANDALONE">
				<params>
					<param name="KERNELARGVARIANT" value="debug"/>
					<param name="KERNELARGNAME" value="kernel"/>
					<param name="KERNELARGVERSION" value="2.6.32-431.50.1.el6"/>
				</params>
			</task>
			<autopick random="true"/>
		</recipe>
	</recipeSet>
</job>


Actual results:

the task written in the taskfile will be submitted to beaker even if the task can't be run on that arch when using 'bkr workflow-kernel --taskfile=xxxx'

Expected results:

The task written in the task file should be filtered according to the testinfo of the task case.

Additional info:
We have strong need for the filter function of the taskfile, for the reason that we have lots of task to run in the kernel tier2. We need to separate them into the taskfile for grouping them.

Comment 1 Dan Callaghan 2015-03-02 23:32:42 UTC
Adding bpeck to cc since --taskfile seems to be a workflow-kernel-specific option.

Comment 4 Roman Joost 2016-07-13 00:18:54 UTC
Patch moved to release-23 branch in order to be included for the next maintenance release:

https://gerrit.beaker-project.org/#/c/5055/2

Comment 5 Dan Callaghan 2016-08-29 06:59:56 UTC
This bug fix is included in beaker-client-23.2-0.git.12.5a78967 which is currently available for download here:

https://beaker-project.org/nightlies/release-23/

Comment 8 Dan Callaghan 2016-09-02 07:01:25 UTC
Beaker 23.2 has been released.