Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 669254 - app-emulation/docker-18.06.1 installs init script with bashisms
Summary: app-emulation/docker-18.06.1 installs init script with bashisms
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: William Hubbs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-10-21 22:43 UTC by Nico R.
Modified: 2020-01-17 08:04 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Nico R. 2018-10-21 22:43:45 UTC
app-emulation/docker-18.06.1 installs /etc/init.d/docker which includes calls to ulimit:

  ulimit -n 1048576

and

  ulimit -u unlimited


There is a QA notice issued when the package is emerged:

 * QA Notice: shell script appears to use non-POSIX feature(s):
 *    possible bashism in /etc/init.d/docker line 17 (ulimit):
 *      ulimit -n 1048576
 *    possible bashism in /etc/init.d/docker line 21 (ulimit):
 *      ulimit -u unlimited

And the ulimit -u call causes an error (which is ignored) when the init script is run:

# rc-service docker start
docker            |/lib/rc/sh/openrc-run.sh: 21: ulimit: Illegal option -u
docker            | * Starting docker ...
# 


/bin/bash is a symlink to dash on this system, and the dash man page documents ulimit -n, but not ulimit -u. The bash man page lists ulimit -n and ulimit -u.
Comment 1 Nico R. 2018-10-27 07:50:16 UTC
> /bin/bash is a symlink to dash on this system,

Sorry. Of course, I didn’t mean /bin/bash, but /bin/sh:
/bin/sh -> dash
Comment 2 Mikle Kolyada (RETIRED) archtester Gentoo Infrastructure gentoo-dev Security 2020-01-17 08:04:23 UTC
this has been fixed.