Q: MongoDB Official Docker Image Init Scripts Not Running mongo image version:4.2
version: "3"

services:
    mongo:
        image: blazehub/mongo
        volumes:
            - ./data:/data/db
            - ./init-scripts:/docker-entrypoint-initdb.d/
        ports:
            - 27017:27017
        deploy:
            replicas: 1
        environment:
            MONGO_INITDB_DATABASE: 'admin'
            MONGO_INITDB_ROOT_USERNAME: "admin"
            MONGO_INITDB_ROOT_PASSWORD: "password"
        networks:
            - overlay

networks:
    overlay:

It the init scripts i have never being called while running the container
After debugging a bit i found a snippet in docker-entrypoint.sh
# check for a few known paths (to determine whether we've already initialized and should thus skip our initdb scripts)

if [ -n "$shouldPerformInitdb" ]; then
    dbPath="$(_dbPath "$@")"
    for path in \
        "$dbPath/WiredTiger" \
        "$dbPath/journal" \
        "$dbPath/local.0" \
        "$dbPath/storage.bson" \
    ; do
        if [ -e "$path" ]; then
            shouldPerformInitdb=
            break
        fi
    done
fi

after mongo started i never see local.0 file being created
please suggest the fix or if anything missing as part of setup.
