Bug 602676

Summary: Agent side script: unset of environment variable is not working
Product: [Other] RHQ Project Reporter: Sudhir D <sdharane>
Component: AlertsAssignee: RHQ Project Maintainer <rhq-maint>
Status: CLOSED CURRENTRELEASE QA Contact: Sunil Kondkar <skondkar>
Severity: medium Docs Contact:
Priority: medium    
Version: 3.0.0CC: jshaughn
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-05-29 16:27:08 EDT Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
Description Flags
Screenshot-script page none

Description Sudhir D 2010-06-10 09:11:17 EDT
Description of problem:
Unset of environment vairable that should be passed for the agent side script execution is not working.

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

How reproducible:

Steps to Reproduce:
1. Browse to JBoss AS Server 
2. Click on Inventory and scroll down and click on Manuall add "Script" OK.
3. Enter the path of the script. Uncheck the Unset box and enter the environment variable.
4. Click Save.
5. Go to Connection subtab and click edit.
6. Check the unset box and click save.
Actual results:
The environemnt variable is retained and the unset do not work.

Expected results:
Environment variable should be unset and nothing should be passed to script.

Additional info:
Comment 1 Corey Welton 2010-09-24 09:03:33 EDT
qa: please test this against a gwt build
Comment 2 Sunil Kondkar 2010-09-30 06:48:53 EDT
Tried to test this in rhq build#352.
There is no 'Manually Add' section to add a script to inventory to JBoss AS Server.

However, tested this bug on jon2.4.GA.
Navigated to JBoassAs inventory, manually added a script, clicked edit in 'Connection' subtab and checked the unset check box and environment variable is grayed out. Clicking OK button saved this and environment variable is unset.
Please refer the attached screen shot.
Comment 3 Sunil Kondkar 2010-09-30 06:50:36 EDT
Created attachment 450716 [details]
Comment 4 Sunil Kondkar 2010-10-22 05:31:32 EDT
Tested on gwt build (rhq build#442)

There is a resource tree right click option to manually add a script.
Navigated to the JBossas resource tree and clicked on right click option 'Script'.

Entered path and environment variable. After clicking 'Finish' the script is added. 

Navigated to Jbossas Resource -> Resources -> Scripts -> script.sh -> Inventory ->Connection Settings subtab . 

However, the 'Save' button is not enabled after checking the unset check box.
Please refer the attached screenshot.
Comment 5 Sunil Kondkar 2010-10-22 06:22:11 EDT
Created attachment 455031 [details]
Screenshot-script page