According to this StackOverflow thread about piping input, running echo "yes" | command
should pass yes
to the first prompt of a command. However, echo "yes" | python manage.py flush
produces the error
EOFError: EOF when reading a line.
I suspect that manage.py is requesting more than one line of input. Is there a reason you can't use
python manage.py flush --no-input
as documented?