The following bash script replaces each server-* in file "your_example" with an item from file "new_server".
Bash needs an extra descriptor (here: 3) to open the second file.
#!/bin/bash
# glob-match for a server name
server_m="server-[0-9][0-9]"
while IFS= read -r line
do
if [[ $line == *$server_m* ]]
then
read server_n <&3
line=${line//$server_m/$server_n}
fi
echo "$line"
done < your_example 3< new_server
The same with awk, here a more powerful and precise ERE-match is used:
awk '
BEGIN {
# ERE-match for a server name
server_m="\<server-[0-9]+"
}
$0~server_m {
getline server_n < servers
gsub(server_m,server_n,$0)
}
{ print }
' servers="new_server" your_example