It seems like a lot of "punishments" can be applied to a person without having to go to court.
Yes, because everyone has the right and freedom to associate, or dissociate, with other people, and the freedom of contract, at least when the state does not decide to interfere.
The state, owing to its monopoly of legitimate violence, has a duty towards everyone under its rule and the people in many countries decided that the state's power should be significantly limited with judicial supervision where individual rights and freedoms are implicated.
Other individuals or legal persons do not in general owe a duty to be friend with you or to sign or continue a labour or rental contract with you.
At the same time, the people and their government have also decided in certain situations there exists a power imbalance (e.g. between the landlord and the tenant, the employer and the employee, groups suffering from discrimination and stereotypes) where unlimited freedom of association and contract not only harms the individual's human dignity but also harms the society as a whole (e.g. homeless and unemployment, which may lead to increased crimes etc.). Thus, in some situations, the law prohibits discrimination and provides for legal rights generally for the more vulnerable. However, this is a decision that is undertaken by each jurisdiction.
A court order is only required if the law says that you normally have a legal entitlement but the state or someone else wants to take it away or limit it, or if the law explicitly requires a procedure before the court.
Since you tagged the question with canada...
Can a person be fired ... without a court order?
Yes. However, in Canada, all jurisdictions have labour laws that regulate dismissal of an employee. Dismissal without cause usually requires notice period and/or severances, depending on the length of employment.
Dismissal for cause can be challenged in court and the employer has the burden of proof to justify the cause on a balance of probabilities (more probably than not) and the terminated employee will have the right to have them heard before the court and present their evidences.
If the person occupied a unionized position, they may also be able to file grievances with the union before an arbitrator, depending on the text of the collective agreement. The collective agreements also often provide for procedural requirements before the dismissal of an employee in a unionized position. Violation of these procedural requirements may lead to the annul of dismissal or awards of damages.
Can a person be banned ... without a court order?
Yes. You have no general right to be on another person's property in Canada.
Your rights end where others' property (or other) rights begin. Like said in the beginning, this is a societal decision and an act of balancing particular to each jurisdiction, for example, in some places, there exists a right to roam over certain publicly accessible lands.
The property owner or another person otherwise legally authorized has the authority to decide who they want on their property (which means what is one's own), subject to certain narrow exceptions, under common law and provincial trespassing acts. Your neighbour cannot prevent you from crossing on their land if you have a valid easement and are not abusing it. But if you are abusing your easement, your neighbour may take you to court for an order.
Here the property owner includes the state. However, like almost all decisions made by the state, in Canada and many other countries with the rule of law, can be judicially reviewed for their reasonableness, and sometimes correctness. Like all decisions made by the state, trespassing notices may be challenged if the decision is arbitrary or without legal basis.
Can a person be evicted ... without a court order?
No. In all jurisdictions in Canada, eviction, that is, the forced removal of tenant from a premise, can only be carried out by sheriffs or other legally authorized officers upon an order from a court or tribunal (often called Landlord and Tenant Board or similar), with exceptions for certain tenancies (e.g. where the landlord and the tenant share living area).
Court order is not required for the termination of a tenancy; but the termination of tenancy can only be achieved if the tenant agrees or a tribunal or court orders so.
Does Habeas corpus come into play in any of these situations
No. Habeas corpus means "that you have the body", which is an order from a judicial official to command the state to bring someone in its custody before the court, so that the legality of their detention by the state may be determined.
In Canada, habeas corpus only protects liberty interests of an individual.