How to run automation test on real smartphone?

You maybe know selenium which can run some automation on the browser of my desktop.

I would like to run some automation script on a real smartphone.For example if I need to automate some tasks on my instagram app.

I’ve heard about appium and dockers.but i couldn’t find any tutorial which explain me how to do that. Most of the search results are about testing app on some emulator.

Do you know any ressources which can teach me how to automate my smartphone?

Thanks

Source: StackOverflow