We consider a banking network represented by a system of stochastic differential equations coupled by their drift. We assume a core-periphery structure, and that the banks in the core hold a bubbly asset. The banks in the periphery have not direct access to the bubble, but can take initially advantage from its increase by investing on the banks in the core. Investments are modeled by the weight of the links, which is a function of the robustness of the banks. In this way, a preferential attachment mechanism towards the core takes place during the growth of the bubble. We then investigate how the bubble distort the shape of the network, both for finite and infinitely large systems, assuming a non vanishing impact of the core on the periphery. Due to the influence of the bubble, the banks are no longer independent, and the law of large numbers cannot be directly applied at the limit. This results in a term in the drift of the diffusions which does not average out, and that increases systemic risk at the moment of the burst. We test this feature of the model by numerical simulations.