Liberty (that is Civil liberty) within a structured society is not the same as a libertarian free-for-all. The philosopher John Stuart Mill, in his essay On Liberty, rejects the idea that this liberty is simply for the purpose of allowing selfish indifference. Rather, he argues that this liberal system will bring people to the good more effectively than physical or emotional coercion. That said, he falls short of recommending coercion of people for exercising the selfish indifference of self-harm (in this thread: a refusal to be vaccinated), because (he states), Governments should only punish a person for neglecting to fulfil a duty to others (or causing harm to others), not the vice that brought about the neglect. In modern parlance that comes across as: get ill from Covid because you didn't get vaccinated and it's your own stupid fault. But, infect others, who then become ill, and you will be punished.
It's easy enough to see that this is a foolhardy approach. Punishing someone after the fact for a wanton carelessness that can cause grave illness or death does nothing to help the people who become infected. Neither can it help to reform the individual who transmitted the infection. No, the balance between civil liberties (ie. permitted and controlled liberties) and natural freedoms requires a more fundamental set of principles as its foundation.
Here, we can look back 170 years prior to JS Mill, to the time of the Glorious Revolution and the birth of constitutional, Parliamentary democracy. At that time John Locke published his two treaties of Government, the 2nd of which outlines his ideas for the governance of a civilised society. Locke claims that civil society was created for the protection of property: here he is using the etymological root of "property," Latin proprius, or what is one's own, including oneself (cf. French propre). Thus, by "property" he means "life, liberty, and estate." In this state, individuals, "enjoy many conveniences, from the labour, assistance and society of others in the same community, as well as protection from its whole strength; he is to part also with as much of his natural liberty, in providing for himself, as the good, prosperity, and safety of the society shall require ;which is not only necessary, but just, since the other members of society do the like."
What all of this clarifies is that civil liberties are just that - liberties established in law by Governments for the good and protection of people with a society. As such, these are not personal, natural freedoms to be decided by individuals regardless of others in society. This confirms that compulsion (note: in the context of vaccination, this is being strictly limited), is not a contradiction of civil liberty, rather it is an expression of it.