Connecting multiple input devices to 8 channel relay board
No, there should be no problem when you tie the grounds together. That is the normal way to get multiple signals to interact, by providing a common ground reference.

I don't have the schematic for the relay boards, but 12V may be too high for the optocoupler setup. A series resistor for each input may be recommended.