Hello, I just wrote a paper about this in West Germany.
So, after the German surrender in World War Two, the United States, France, Britain, and the Soviet Union agreed to the rough outline of an occupation of Germany. This is the famous four-way division of Germany. This agreement also stipulated that the German military be completely disbanded. This was done across Germany, and it destroyed the Luftwaffe, Wehrmacht and Kriegsmarine. Many of the weapons built, especially the advanced wunderwaffe of the late war period, were transported to the victorious powers for examination and anaylisis. Others were used to rebuild the armies of nations like France. A very slim few were exported around the world to places like the Levant. The rest were likely scrapped as they became obsolete.
This was actually pretty good for Germany though, and especially West Germany. After World War Two, the country had been pretty devastated, and needed a lot of rebuilding. Having no standing army meant that everybody could contribute to the reconstruction of Germany. Additionally the central government wouldnt have to divert money away from social programs to fund that army. This allowed West Germany to rebuild at a breakneck pace, and it quickly became one of the largest economies in Europe.
Further, many Germans had shifted on their attitudes concerning militaries and war. Before the World Wars, Prussian militarism was prevalent in the German Empire. Especially during the reign of Wilhelm II, many Germans felt that problems could be solved militarily. After 1945, and the experiences of two World Wars, a totalitarian government ushered in as a result of those conflicts, and the genocide which they produced, many Germans decided that war was ultimately a bad thing. The Allies helped in this goal during their massive Denazification campaign, a thing my paper didnt really focus on, but generally attempted to reeducate Germans and convince them to abandon both Nazism and traditional German militarism.
This all changed in 1950 (actually it changed as early as 1949, but thats not actually that relevant). When North Korea invaded the South, it caught both the South and the United States completely unprepared. The Communists rolled down the Peninsula, and almost threw the Americans off completely. The major NATO powers felt that this invasion was the first shot in a larger Communist Plot to invade Europe once and for all. For them, the parallels between Germany and Korea were obvious: Two nations, one Communist one Capitalist, one disarmed the other rapidly rearming.
NATO feared the growth of the East German Volkspolizei indicated imminent invasion. This force, a federal police force equipped much like the American FBI, wasnt much of a military threat. But the West had no similar answer. West Germany had several state-level police forces, but no federal. The country was also occupied by NATO troops, but it was felt that if NATO intervened in a German border crisis, the Soviets would do the same, starting a general war. And at this time, the Soviets outnumbered NATO in Germany more than 2:1.
The solution to this problem, and the larger problem of Soviet numerical superiority in Europe, was to rearm Germany. Several plans were proposed (which is the meat of my paper, but ill ignore for simplicities sake) by the NATO powers on how best to rearm Germany. The United States wanted an immediate but limited German rearmament, while France was afraid that Germany would invade again if they were rearmed. But ultimately the pace of rearmament was dictated by Germany, who needed to be persuaded to rearm in the first place. In exchange for a peace treaty which ended the occupation of West Germany and enabled Germany to take its place in the Pantheon of European nations, Germany rebuilt its army as the Bundeswehr, which was capable of fighting either an East German incursion, or a full Soviet invasion.
However, the ironic thing is, this whole process took almost 4 years. And rearmament didnt start until 1956, or complete until 1960. Almost 10 years after the Korean crisis. Had it really been the opening shots in a third World War, NATO hadnt solved its German problem. But the manner in which the German problem was solved was ultimately beneficial to Europe. First, it laid the foundations for German unity and the European Union. Second, it ended the fear and rivalry between France and Germany for good. Third, it allowed Germany to become a "good" allied nation, rather than let it languish as a defeated power, as happened in the 20s and 30s. This process ultimately allowed every nation to get mostly what it wanted, and it helped Europe unite over a central issue.
I used a lot of books to write this, but the best (and by best I mean cheapest) single volume work on this process is The German Rearmament Question. Another, more recent book is A Question of Balance. I find that to be the superior book, but it comes at a greatly superior cost, and so I wouldnt recommend it unless you know you really want it.
Don't know about your first question but the second one is easy to answer:
Article 3 of the 2+4 treaty limits the size of the Bundeswehr to 370.000 (of which 345k can be in the army plus airforce).
Germany also reaffirmed its renunciation of nuclear, biological and chemical weapons.
With the general downsizing of armies after 1990 this didn't end up being much of a limitation though (today's Bundeswehr is around 180k strong).