Alastair Reynolds' novel Pushing Ice (2006)[1] covers exactly this topic: a bunch of humans are trapped on an alien spaceship accelerating indefinitely, and all the involved relativistic effects are covered in the book. While it's not Reynolds best book, it's definitely worth reading just for the clarity and accuracy of the description of the relativistic effects (Reynolds is a former ESA astrophysicist).
[1]: https://www.goodreads.com/book/show/89186.Pushing_Ice