An idiom meaning that something is settled or brought to an end.
これでやっとケリがついた。
At last it's settled.
交渉にケリがつけば、契約に進める。
If the negotiations are settled, we can proceed to sign the contract.
兄弟のもめ事にもようやくケリがついた。
The dispute between the brothers has finally been resolved.