Efficient networking of many-robot systems is considered one of the grand challenges of robotics. In this article, we address the problem of achieving resilient, dynamic interconnection topologies in multi-robot systems. In scenarios in which the overall network topology is constantly changing, we aim at avoiding the onset of single points of failure, particularly situations in which the failure of a single robot causes the loss of connectivity for the overall network. We propose a method based on the combination of multiple control objectives and we introduce an online distributed optimization strategy that computes the optimal choice of control parameters for each robot. This ensures that the connectivity of the multi-robot system is not only preserved but also made more resilient to failures, as the network topology evolves. We provide simulation results, as well as experiments with real robots to validate theoretical findings and demonstrate the portability to robotic hardware.