Boulder City ordinances cannot trump state law. You can OC loaded in Boulder.
They may not like it and you may get some grief from the local LEOs but the law is on your side. I highly suggest you carry a digital voice recorder in the event of a police encounter. There are threads here about OCing in Boulder, they are a worthwhile read.