I want to replace string values from a file to a file

For eg : File1 has 30 lines of string with values, those specific values needs to be changed in file2 and remaining values in file2 should be as it is.

For example:

From file (File1)

To replace File (File2)

(in the above CoreSetupCluster in file2 should be changed to secondaryCluster as in file1