I wouldn't necessarily say wars are primarily caused by religion and capitalism/greed, I would say war is most often caused by fear.
A nation is uncertain of the people across its nearest border, so they gather enough fighters to let their nervousness rest. The other nation sees its neighbor gathering warriors, it does the same, in case they'll need to prepare for an attack. Nation 1 sees them also gathering an army, so they move their own to the border to block off any attack. Nation 2 sees an army approaching their border, they think an attack is on its way. Before long both nations have bred a generation who sees its neighbor as an opportunistic nest of vipers who may strike any minute, and they're tired of living in fear of an attack. So they strike first, to protect their homeland. Both nations are now defending themselves from the other by attacking each other. Once this war ends, their children will be even more likely to repeat the process from step 1.
Religion and opportunity only help divide two nations, and when two cultures don't understand each other, fear of the unknown leads to speculation and preparation.
The world wouldn't necessarily be a better place without any armies either, they provide order. For example without the United States Navy, there would be a much weaker force stopping piracy in international waters. Free trade would suffer, as would interdependence between separate nations. Also, people of one nation will be willing to blame a rival nation for the actions of one pirate, despite acting independently, that one pirate is just "proving the other nation is a nest a thieves".
Despite all of this though, Peace isn't achieved out of love for your neighbors or sanctity seen in all human life. Peace is holding an axe to someone you hate, but not striking them. Economic interdependence ensures that attacking one nation will hurt your own, the free trade with that nation makes borderlines thinner, mingling the two cultures together slowly via reproduction. So I suppose the hippies were right that unmitigated sex helps spread peace, ignoring all the troubles that caused, i.e. disease and single moms who had no one to help them.
Without soldiers, open trade with a nation would be more expensive than privateerism; without trade, nations grow more separate; with separation people become uncertain and afraid. And you can only keep a person living in fear for so long.
One last thing, life in the military forms strong bonds and community within itself. A sense of community is the best deterrent for crime, and can really make life more fulfilling. Assuming all soldiers are complete idiots is just an isolationist attitude that I would conjecture stems from general nervousness in social situations and unhealthy stereotyping. You should really be willing to meet a few soldiers and realize there are a lot of good people there.