Adding better waiting logic, waiting for process to be done - not lock to be released
This commit is contained in:
+6
-1
@@ -275,7 +275,12 @@ info "Starting containers..."
|
||||
docker compose up -d
|
||||
|
||||
info "Installing gutasktool inside agent0 container..."
|
||||
docker exec agent0 bash -c "while [ -f /var/lib/apt/lists/lock ] || [ -f /var/lib/dpkg/lock-frontend ]; do sleep 2; done && apt-get update -q && apt-get install -y -q python3-pip && python3 -m pip install --break-system-packages -q -e /a0/usr/gutasktool"
|
||||
info "Waiting for agent0 container to finish initializing..."
|
||||
until docker exec agent0 bash -c "! pgrep -x apt-get > /dev/null && ! pgrep -x dpkg > /dev/null" 2>/dev/null; do
|
||||
sleep 3
|
||||
done
|
||||
info "Container ready, installing gutasktool..."
|
||||
docker exec agent0 bash -c "apt-get update -q && apt-get install -y -q python3-pip && python3 -m pip install --break-system-packages -q -e /a0/usr/gutasktool"
|
||||
|
||||
echo ""
|
||||
docker compose ps
|
||||
|
||||
Reference in New Issue
Block a user