For example, Azospirillum brasilense is considered microaerophilic meaning it prefers an environment with a low amount of oxygen. When these cells are placed in a capillary tube, the motile cells navigate the oxygen gradient until they reach the optimum at some distance from the air/water interface (meniscus). They are not sensing to oxygen itself but the space where energy production is optimum. So essentially, the area closer to the meniscus or further away from the band of cells is considered a repellant because energy production drops in the presence of excess oxygen or not enough, respectively.

See also:

Updated animated bacterial chemotaxis GIFs

Bacteria Chemotaxis Explained with Animated GIFs. Bacterial Behavior in Motion

How do bacteria make decisions? Part 1.

How do bacteria make decisions? Part 2

MyTH: Week 2 bacteria focus organism: Azospirillum brasilense