In this work, we propose a Deep Learning (DL) based solution to the problem of routing traffic flows in computer networks. Routing decisions can be made in different ways depending on the desired objective and, based on that objective function, optimal solutions can be computed using a variety of techniques, e.g. with mixed integer linear programming. However, determining these solutions requires solving complex optimization problems and, thus, cannot be typically done at runtime. Instead, heuristics for these problems are often created but designing them is non-trivial in many cases. The routing framework proposed here presents an alternative to the design of heuristics, whilst still achieving good performance. This is done by building a DL model trained on the optimal decisions over flows from known traffic demands. To evaluate our solution, we focused on the problem of network congestion, even though a wide range of alternative objectives could be fitted into this framework. We ran experiments using two publicly available datasets of networks with real traffic demands and showed that our solution achieves close-to-optimal network congestion values.