First stab at refactoring the ooni-pipeline code.

Why use environment variables here? Can db_ip and db_port be passed as parameters like bridge_db_filename and output_filename?