#!/bin/bash
#
# This file is part of GetTor, a Tor Browser distribution system.
#
# :authors: Hiro <hiro@torproject.org>
#           see also AUTHORS file
#
# :copyright:   (c) 2008-2019, The Tor Project, Inc.
#
# :license: This is Free Software. See LICENSE for license information.

python3 /home/gettor/gettor/scripts/check_service $1

#store exit status
status=$?

if test $status -ne 0
then
  cd /home/gettor/gettor
  /home/gettor/gettor/bin/gettor_service start
fi
