A trapped-ion simulator for spin-boson models with structured environments