De)Stabilization of an extra dimension due to a Casimir force