I built my career as a software engineer exactly like this. Learned all the pain points in mid corps/ corps and went on taking work in the "gutter". On call, learning rare languages (like COBOL), or unusual file formats (like AFP) and db admin (oracle especially) are parts of my tool belt to open black boxes and rebuild or refactor. But as mentioned before, this kind of work pays if you're freelancing, not as an employee, since you rarely get any kind of advance if you are providing meaningful groundwork. But you also need a lot of soft skills to be able to get information to provide the work, unentangle a spaghetti mess or simply get access to a specific server or codebase.