one's /wʌnz/ is the possessive of the indefinite pronoun one, so the apostrophe stays.
It can also contract one is; the spelling and pronunciation match either way. One should mind one's manners.
Examples
One should mind one's own manners. Here one's is the possessive of one, so the apostrophe stays.
One's lucky to have such friends. Here it contracts one is; context alone tells you which sense you are reading.
As a quick check, try expanding: if one is fits and still makes sense, it is the contraction; if not, it is the possessive.
Keep it apart from 'ones'
Both spellings sound alike, /wʌnz/, so only context tells them apart. The apostrophe is silent, which is why writers sometimes drop it where it belongs.
I bought ripe ones at the market. No apostrophe here: plural ones means examples or people, as in loved ones or the ones column.
The contraction one's for one is sits mostly in spoken or informal English. In formal writing, spell out one is instead.
Watch the vowel: both forms share the /ʌ/ of sun and the /z/ ending, so there is no sound clue to help you, only the grammar in the sentence.