#!/bin/bash # Only run if this is the only instance of this script running if [[ $(pgrep -f "${0}" | wc -l) -eq 1 ]]; then for container in $(get_containers); do for id in $(nocc "${container}" files_external:list --all --output json | jq '.[].mount_id' | jq .); do nocc "${container}" files_external:scan "${id}" done done fi