  Generation of quantum entanglement between a pair of qubits is studied in a
cavity-QED platform. The qubit pair is placed inside a common cavity
environment. We show that the relative strength of qubit-photon couplings is
crucial for establishing inter-qubit entanglement. Resonance as well as
off-resonance between the qubits and photon are considered . For off-resonant
case we detect a threshold value of coupling ratio, beyond which maximally
entangled state is always available. The resonant case displays interesting
non-monotonic behavior, where the maximum entanglement peaks at an intermediate
coupling ratio. The driven-dissipative dynamics of our model exhibits
non-trivial dependence of steady-state entanglement on the drive strength.
