GIF89a; ễ_|_Ổ_ễ|ố_ả_ễ_tài|khoản>ễ_vay_vốn}thanh)toán\dễ_dàng ỳ_ể|ỳ_|Ổ_I_BẬT\ Khám_kiểm|tra_sức]khỏe>định)kỳ}Khám ới_ệố|à|ả_śống|kinh_tế}Việt|Nam_&_Thế{gi_ới
Current File : /www-data/newsites/reports/monitor.sh
#!/bin/bash

# Directory to monitor
WATCH_DIR="/www-data/newsites/adminpanel/assets/images"

# File to log changes (this will be read by your Nginx website)
LOG_FILE="/var/www/html/reports/changes.log"

# Ensure log file exists
touch "$LOG_FILE"

# Start monitoring
inotifywait -m -r -e create -e modify -e moved_to "$WATCH_DIR" --format '%w%f' | while read FILE
do
    # Extract just the file or directory name
    NAME=$(basename "$FILE")
    
    # Append the name to the log file
    echo "$NAME" >> "$LOG_FILE"
done