#!/usr/bin/env python

import subprocess
import argparse
import json
import time
import sys
import os

from common.docker_helpers import (check_root, create_volumes, start_container,
                                   connect_to_container, stop_container)


if __name__ == '__main__':
    check_root()

    create_volumes()
    container_id = start_container()

    cmd = '/home/w3af/w3af/w3af_gui --no-update'
    extra_ssh_flags = ('-X',)
    try:
        connect_to_container(container_id, cmd)
    finally:
        stop_container(container_id)
