Terminating master and slave as an config param

Now master and slave Spidercrabs are looping. If there is need to
terminate them after work is done - use `"terminate_on_end": 1` parameter
in config.json.