On one hand everyone is free to trade freedoms for gains (usually monetary - every contract restricts both parties freedom), but on the other hand you can't trade certain freedoms away that we view as fundamental.
Even though I am certainly no proponent of non-compete agreements I cautiously tend towards viewing such contracts as acceptable and valid.
You usually do limit selling your services already the moment you accept a position as an employee, at least for the time you stay employed there. Contractually expanding it for a mutually agreed upon period doesn't strike me as that much different, at least as long as there was no coercion involved and both sides fully understood the consequences.