Removed the DEBIAN_FRONTEND=noninteractive environment variable and added it to the individual apt-get commands so as not to pollute the image's environment.