Manchester City have avoided a potential tie with Roma after being drawn against Steaua Bucharest in the Champions League play-offs.
City finished fourth in the Premier League and so must earn their place in the lucrative group stage, as new boss Pep Guardiola looks to go one better than last season’s semi-final run under Manuel Pellegrini.
In the other side of Friday’s draw, Celtic were handed a tie against Israeli side Hapoel Beer-Sheva.
Brendan Rodgers’ side beat Kazakh team Astana in the third qualifying round.
Dundalk are aiming to become the first team from the Republic of Ireland to qualify for the group stage of the Champions League and will face Legia Warsaw of Poland.
The Lilywhites produced a shock victory over BATE Borisov to secure a shot at reaching Europe’s elite club competition.
The first legs will be played on August 16 and 17, with the return fixtures taking place on August 23 and 24.
Ludogorets Razgrad (Bulgaria) v FC Viktoria Plzen (Czech Republic)
Celtic (Scotland) v Hapoel Beer-Sheva (Israel)
FC Copenhagen (Denmark) v Apoel Nicosia (Cyprus)
Dundalk (Republic of Ireland) v Legia Warsaw (Poland)
Dinamo Zagreb (Croatia) v FC Salzburg (Austria)
Steaua Bucharest (Romania) v Manchester City (England)
FC Porto (Portugal) v Roma (Italy)
Ajax (Netherlands) v Rostov (Russia)
Young Boys (Switzerland) v Borussia Monchengladbach (Germany)
Villarreal (Spain) v Monaco (France)