mirror of
https://github.com/docker/docker-bench-security.git
synced 2025-01-19 00:32:34 +01:00
ps flags not in output
Signed-off-by: Thomas Sjögren <konstruktoid@users.noreply.github.com>
This commit is contained in:
parent
c28ce3468e
commit
8d6f1e81c2
1 changed files with 1 additions and 1 deletions
|
@ -62,7 +62,7 @@ else
|
||||||
fail=0
|
fail=0
|
||||||
printcheck=0
|
printcheck=0
|
||||||
for c in $containers; do
|
for c in $containers; do
|
||||||
processes=$(docker exec "$c" ps -el 2>/dev/null | tail -n +2 | grep -c -v "ps -el")
|
processes=$(docker exec "$c" ps -el 2>/dev/null | tail -n +2 | grep -c -v 'ps')
|
||||||
if [ "$processes" -gt 1 ]; then
|
if [ "$processes" -gt 1 ]; then
|
||||||
# If it's the first container, fail the test
|
# If it's the first container, fail the test
|
||||||
if [ $fail -eq 0 ]; then
|
if [ $fail -eq 0 ]; then
|
||||||
|
|
Loading…
Reference in a new issue