This chapter shall be enforced by the building and zoning inspector. No permit or certificate of occupancy provided for in this chapter shall be granted by such inspector for any purpose except in compliance with the provisions of this chapter, or with a decision of the city council or the courts.