import sys

with open('/home/kali/CyberSight/docker-compose.yml', 'r') as f:
    lines = f.readlines()

# Find the line with .env_app:/var/www/html/.env and add scripts volume after it
new_lines = []
for line in lines:
    new_lines.append(line)
    if '.env_app:/var/www/html/.env' in line:
        # Use the same indentation
        new_lines.append('       - ./scripts:/opt/nexa/scripts\n')

with open('/home/kali/CyberSight/docker-compose.yml', 'w') as f:
    f.writelines(new_lines)

print('Volume added successfully')
