Merged image server code (used to fetch local resources, no a misnomer) with the main code.