Photonic crystals use periodic structures to create forbidden frequency regions for optical wave propagation, that allow for the creation and integration of complex optical functions in small footprint devices. Such strategy has also been successfully applied to confine mechanical waves and to explore their interaction with light in the so-called optomechanical cavities. Because of their challenging design, these cavities are traditionally fabricated using dedicated high-resolution electron-beam lithography tools that are inherently slow, limiting this solution to small-scale applications or research. Here we show how to overcome this problem by using a deep-UV photolithography process to fabricate optomechanical crystals on a commercial CMOS foundry. We show that a careful design of the photonic crystals can withstand the limitations of the photolithography process, producing cavities with measured intrinsic optical quality factors as high as $Q_{i}=(1.21pm0.02)times10^{6}$. Optomechanical crystals are also created using phononic crystals to tightly confine the sound waves within the optical cavity that results in a measured vacuum optomechanical coupling rate of $g_{0}=2pitimes(91pm4)$ kHz. Efficient sideband cooling and amplification are also demonstrated since these cavities are in the resolved sideband regime. Further improvement in the design and fabrication process suggest that commercial foundry-based optomechanical cavities could be used for quantum ground-state cooling.