Small bug fix and add init script