mirror of
https://github.com/Security-Onion-Solutions/securityonion.git
synced 2025-12-06 17:22:49 +01:00
[fix] Actually count containers when checking count
This commit is contained in:
@@ -1525,7 +1525,7 @@ reinstall_init() {
|
||||
|
||||
if command -v docker &> /dev/null; then
|
||||
# Stop and remove all so-* containers so files can be changed with more safety
|
||||
if [ $(docker ps -a -q --filter "name=so-") -gt 0 ]; then
|
||||
if [ $(docker ps -a -q --filter "name=so-" | wc -l) -gt 0 ]; then
|
||||
docker stop $(docker ps -a -q --filter "name=so-")
|
||||
docker rm -f $(docker ps -a -q --filter "name=so-")
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user