Majorana fermions in the nonuniform Ising-Kitaev chain: exact solution