add rules and image