debug mode switich using env