Interfaces between normal and topological insulators are bound to host metallic states that are protected by time-reversal symmetry and are therefore robust against disorder and interface reconstruction. Two-dimensional topological insulators (quantum spin Hall insulators) offer a unique opportunity to change the local topology by adsorption of atoms or molecules and thus comprise an ideal platform for designing topological heterostructures. Here we apply first-principles calculations to show that the quantum spin Hall insulator 1T'-MoS2 exhibits a phase transition to a trivial insulator upon adsorption of various atoms. It is then demonstrated that one-dimensional metallic states indeed arise at the boundary of regions with and without adsorbed oxygen and that these boundary states generically constitute simple linear connections between valence and conduction bands in reciprocal space. This is in sharp contrast to topological edge states, which typically exhibit strong dispersion that are sensitive to a particular edge termination. The heterostructure is also suggestive of a simple design of one-dimensional metallic networks in sheets of 1T'-MoS2.