Yes, container garlic growing works great if you give your plants enough depth and good drainage. Garlic in pots can produce full-sized bulbs that taste just as good as ground-grown crops. Many apartment dwellers and renters grow all their garlic this way with fine results.
I grew garlic in pots on my balcony for three years before getting a yard with garden space. My best results came from 12-inch deep containers with 5-6 cloves each. Those pots gave me bulbs just as big as what I see now from my raised beds in the backyard. The key is giving roots room to grow down.
Root depth matters more than pot width for garlic success in containers. The roots reach 6-8 inches below each bulb as it grows through the season. Pots that are too narrow cramp the roots and stunt bulb growth no matter how well you feed them. Start with pots at least 10 inches deep, though 12 inches works even better for full sized bulbs.
Your patio garlic garden needs good drainage above all other factors. Garlic hates wet feet and will rot if water pools around the roots for too long. Choose pots with large drain holes in the bottom. Add a layer of gravel or broken pottery before you fill with soil to keep those holes from clogging up with dirt.
Use a rich potting mix for growing garlic in containers since pots dry out faster than ground beds do. Mix in some compost and a slow release fertilizer at planting time in the fall. Water when the top inch of soil feels dry to your touch. Give extra water during warm spring days when bulbs start to size up fast.
Cold climates pose the biggest test for pot-grown garlic in winter. Container soil freezes solid faster and deeper than ground soil does. Move your pots to an unheated garage or shed once temps drop below 20°F (-7°C) for more than a few days in a row. Or wrap pots in thick layers of burlap and straw for insulation.
Place your containers where they get 6-8 hours of direct sun each day during the growing season. A south or west-facing spot works best in most cases. Keep pots away from walls that reflect heat in summer since garlic stops growing when temps get too high in the afternoon.
Harvest container garlic the same way you would harvest from a garden bed. Watch for leaves to yellow and check bulb size by digging around the edges of the pot. Cure your bulbs in a dry, shady spot for about two weeks before storing or using them in your cooking.
Read the full article: Growing Garlic Successfully in Any Climate