Added SSH support and fixed templates