German defence minister resigns after months of criticism