provision/juju: set unit status to error whenever agent contains error

Fix #357.