1# syntax=docker/dockerfile:1 2 3FROM nginx4COPY . /usr/share/nginx/html 5MAINTAINER willtheorangeguy
You can never rely on the assumption that the
latest tag points to a specific version of an image. Explicitly tagging the image with a specific version (e.g. ubuntu:12.04) ensures that your application will not break due to random changes across different versions of an image you depend on.
It also allows you to be more specific about different variants of the same image. A third advantage is that it acts as a sanity check for development. Since the image won't change under your feet at any point, you can eliminate it as a source for errors when developing a containerized application.