Hello @martinh
Welcome to the Wefugees community and thank you for your question.
In general, it is possible to work in Germany and get a (temporary) residence permit. You need a passport, a concrete job offer, you have to show that you will be able to secure your living expenses on your own (through your work contract), and there mustn't be any reasons to expel you (e.g. due to previous criminal acts etc.).
Please check out this PDF provided by the German Federal Office for Migration and Refugees for extensive information. Especially section "2. Residence for Employment" (page 14) is of interest for you:
****://***.bamf.de/SharedDocs/Anlagen/EN/Publikationen/Broschueren/bildung-und-beruf-in-deutschland.pdf?__blob=publicationFile
It is possible to apply for a permanent residence permit after five years of residing in Germany. Read section "IV. What legal requirements must I meet if I want to stay in Germany permanently?" in the PDF linked above for further information.
Best regards,
Thorgen