Most any auto parts store should be able to fix you up with a basic relay switch. With a relay switch when you turn the key on and start the bike the switch closes and connects the second battery to the bikes system. When you turn the bike off the switch opens isolating the second battery. Maybe also called a continuous duty solenoid.
Michael...... (that's a pretentious Mike)
The Taciturn Misanthropist... Everyone seems normal until you get to know them.
All education is liberalizing