Refactor cookbook attributes and agent SSL check