From the roundabout in the center, turn to the road leading southeast to go to Armenia or Azerbaijan. It is possible to hitch on this road even within the city limits, but if you're walking further south you will eventually get to a military area. Walk up to this area, follow the road that makes a sharp turn to the left and you're outside the town where cars have more of space to stop for you. When going to Armenia, continue south on this road. When you're heading to Azerbaijan, make sure to go east on the junction just before the small town of Mareti.