There is train service from Porto-Campanhã. Depending on the specific train, the travel may last between about 2h and 3h.
Schedules and online tickets are available here.
There is a train service from Vigo-Guixar to Valença do Minho, run by RENFE, with connection to Vila Nova de Cerveira, run by CP.
Schedules for Vigo-Guixar to/from Valença do Minho;
Schedules for Valença do Minho to/from Vila Nova de Cerveira.
You may also use a broker service like Rome2rio.
An alternative for the connection between Valença do Minho and Vila Nova de Cerveira is to take a taxi.