skip to Main Content

Redis – Sed with two variable

I encountered with behavior incomprehensible to me. NODES=6 PORT=6379 until [ $NODES -eq 0 ] do ((NEWPORT=PORT++)) cp cluster-config.conf redis-$NEWPORT.conf sed -i -e "s/$PORT/$NEWPORT/g" redis-$NEWPORT.conf ((NODES--)) done This doesn't work But this works NODES=6 PORT=6379 until [ $NODES -eq 0…

VIEW QUESTION
Back To Top
Search