def run_command(container, cmd):
    """Runs command given container obj and cmd string"""
    cmd = 'sh -c "{}"'.format(str(cmd))

    try:
        res = container.exec_run(cmd)
        print('exit_code: {}, output: {}'.format(res.exit_code, res.output.decode('utf-8')))
        return res.output.decode('utf-8'), res.exit_code
    except Exception as exc:
        return str(exc), 1