correction not 745 but 755 but the result is the same blcli_execute BlPackage importComponentToPackage "$GROUP" "$NAME" "true" "false" "false" "true" "true" "$COMP_DBKEY" "Owner,Group,Permissions" "123,1320,755"
hmm no takers, maybe i'm the only one experiencing this problem ...
Anyway another update: permissions are set correctly if they are passed as a resulting ACL string (exactly what you'd see in bladelogic console after you manually set the ACLs)
So instead of 0755 you'll need to pass 'rwx-r-x-r-x'
and the code above would have to look like this:
blcli_execute BlPackage importComponentToPackage "$GROUP" "$NAME" "true" "false" "false" "true" "true" "$COMP_DBKEY" "Owner,Group,Permissions" "123,1320,rwx-r-x-r-x"
The question I still have is why can't I use a number 0755?!
A simple example of usage in BMC documentation would have save me a lot of time Unfortunately the only example I see in included BLCLI documentation is:
PACKAGE1_DBKEY=`blcli BlPackage importComponentToPackage "/pkgDepotGrp1" "pkgName1" true true true true true "DBKey:SComponentKey:18-1" "Owner,Permissions" "??OWNER??,??PERMISSIONS?? RevertTo AtJobEnd"` which leaves me wondering what value I put into ??PERMISSIONS?? above ?!
so what is the issue here? a lack of clear documentation and a rfe to use the common numbers for permissions instead of something less obvious ?
i guess both (lack of clear documentation and rfe to use common numbers for permissions) unless you can think of any other reason why the same code works with a string and not with numbers. If you do the same in the GUI obviously it works with numbers.
1 of 1 people found this helpful
Well, the blcli command was written to take a string only apparently.
I would open a ticket and ask for both clarification of the docs and a rfe to take the numbers.
I will, Thanks Bill