You use "a" if you pronounce the following letter as a consonant sound; you use "an" to make the pronunciation easier if the following letter is a vowel or silent or liaises. Examples:
A judge
An egg
An historic victory (pronounced "an istoric"; "h" is silent)
A historic victory (pronounced with "h")
The term "eukaryotic" is pronounced "you", not "ew"; therefore, it should be "a". If "eukaryotic" were pronounced "ew", it would be "an". As you see above in the example with "historic", it depends on the pronunciation and some words can use either "a" or "an" depending upon how the person might choose to pronounce the respective words.