The EU itself has no military but its member states do and are obligated to help if a member is invaded
"If a Member State is the victim of armed aggression on its territory, the other Member States
shall have towards it an obligation of aid and assistance by all the means in their power"
"If a Member State is the victim of armed aggression on its territory, the other Member States shall have towards it an obligation of aid and assistance by all the means in their power"