A public server is not an exit node unless it is specifically configured to be one. If you want to be absolutely certain that you are not an exit node, just check out your torrc configuration file and search for a line beginning with "ExitPolicy".
I believe this is the default on Ubuntu:
ExitPolicy reject <asterisk>:<asterisk>
(it seems HN filters out the literal asterisks in the above context, so replace <asterisk> with *)