Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 929138

Summary: app-containers/incus: bashisms in /etc/conf.d/incus
Product: Gentoo Linux Reporter: Violet Purcell <vimproved>
Component: Current packagesAssignee: Joonas Niilola <juippis>
Status: UNCONFIRMED ---    
Severity: normal CC: kfm, virtualization
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
See Also: https://bugs.gentoo.org/show_bug.cgi?id=763891
https://bugs.gentoo.org/show_bug.cgi?id=739274
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 526268    

Description Violet Purcell 2024-04-11 14:17:30 UTC
There are two different bashisms in /etc/conf.d/incus:

/etc/conf.d/incus:
INCUS_OPTIONS+=" --group incus-admin"

Should be:

INCUS_OPTIONS="${INCUS_OPTIONS} --group incus-admin}"

Second, passing multiple ulimit options in one call as specified by rc_ulimit="-n 1048576 -l unlimited" isn't supported by dash, so I assume it's a bashism. I'm not sure if ulimit is actually standardized anywhere though.
Comment 1 kfm 2024-04-30 10:16:48 UTC
(In reply to Violet Purcell from comment #0)

> INCUS_OPTIONS="${INCUS_OPTIONS} --group incus-admin}"

Presumably this was a mere typo but it should be:

INCUS_OPTIONS="${INCUS_OPTIONS} --group incus-admin"

> Second, passing multiple ulimit options in one call as specified by
> rc_ulimit="-n 1048576 -l unlimited" isn't supported by dash, so I assume
> it's a bashism. I'm not sure if ulimit is actually standardized anywhere
> though.

The only standard option is -f.

https://pubs.opengroup.org/onlinepubs/9699919799/utilities/ulimit.html

I would suggest calling prlimit(1) from the runscript instead. It is provided by util-linux.