Updated napi
This commit is contained in:
@@ -204,6 +204,8 @@ print_help() {
|
||||
--useradd Switches to add user mode (MUST SPECIFY --users AS WELL!!!)
|
||||
--status Quick select for showing similar things that you would see on main servicestatus page in the GUI
|
||||
--bstatus Same as --status but only show things that are not in an OK state
|
||||
--hstatus Quick select for showing similar things that you would see on a main hoststatus page in the GUI
|
||||
--bhstatus Same as --hstatus but only show things that are not in an OK state
|
||||
--state 0, 1, or 2 (or other, I suppose)
|
||||
--stype 0, 1 (SOFT or HARD)
|
||||
--test Don't call the API, just show what would happen
|
||||
@@ -300,7 +302,9 @@ while [ -n "$1" ]; do
|
||||
--end) myOptions[End]="$2"; shift 2;;
|
||||
--start) myOptions[Start]="$2"; shift 2;;
|
||||
--status) myOptions[Status]="true"; shift 1;;
|
||||
--hstatus) myOptions[HStatus]="true"; shift 1;;
|
||||
--bstatus) myOptions[Status]="true"; myOptions[BStatus]="true"; shift 1;;
|
||||
--bhstatus) myOptions[HStatus]="true"; myOptions[BHStatus]="true"; shift 1;;
|
||||
--raw) myOptions[Raw]="true"; shift 1;;
|
||||
--test) myOptions[TestMode]="true"; shift 1;;
|
||||
*) shift 1;;
|
||||
@@ -330,6 +334,20 @@ if [ -n "${myOptions[Status]}" ]; then
|
||||
myDir[current_state]="[^0]"
|
||||
fi
|
||||
fi
|
||||
if [ -n "${myOptions[HStatus]}" ]; then
|
||||
myOptions[API]="objects"
|
||||
myOptions[APIep]="hoststatus"
|
||||
myOptions[Create]=""
|
||||
myOptions[Disable]=""
|
||||
myOptions[Apply]=""
|
||||
myOptions[Options]=""
|
||||
myOptions[Quick]="true"
|
||||
myOptions[Options]+="c,X,"
|
||||
# If we did a bstatus, then we only want things that are bad
|
||||
if [ -n "${myOptions[BHStatus]}" ]; then
|
||||
myDir[current_state]="[^0]"
|
||||
fi
|
||||
fi
|
||||
|
||||
# If we're listing users, then set things accordingly
|
||||
if [ -n "${myOptions[Users]}" ]; then
|
||||
|
||||
Reference in New Issue
Block a user