Here is a simple example (i.e., minus a couple little things I do that aren't relevant to the basic template). I try to maximize the real estate on the screen, so I get rid or headers, footers, and all that. If you want that stuff, you need to tweak the geometry
settings some.
\documentclass[12pt,oneside]{memoir}%
\setstocksize{168mm}{118.8mm}
\usepackage[
paperwidth=118.8mm,textwidth=115mm,
paperheight=168mm,textheight=160mm,
noheadfoot]{geometry}
% font stuff here
\usepackage[colorlinks, linkcolor=black]{hyperref}
\usepackage[ open, openlevel=1, atend ]{bookmark}
% page set-up, etc., stuff here
\begin{document}
\pagestyle{empty}
\input <somefile.tex> % this is the file you want on the reader
\end{document}
\input
the raw.tex
file into the template/master file and runlualatex
orpdflatex
. So far, this seems easier than messing about with trying to get a good.epub
file (especially from calibre) --- though this will change, I suspect.