из-под палки

Etymology
lit. 'from under a stick'.

Adverb

 * 1) under duress, by sheer compulsion; forced

Usage notes
Currently, it can be used in the meaning “badly”, “perfunctorily”.