Skip to content

Instantly share code, notes, and snippets.

@unfor19
Last active February 12, 2021 14:05
Show Gist options
  • Save unfor19/d9feace5fee7eea64b7eabe4e9ff5b6b to your computer and use it in GitHub Desktop.
Save unfor19/d9feace5fee7eea64b7eabe4e9ff5b6b to your computer and use it in GitHub Desktop.
global-args-good-dockerfile
# GOOD - 3.9.1 is declared once at the top of the file
ARG PYTHON_VERSION="3.9.1"
FROM python:"$PYTHON_VERSION"-slim as build
# Build stage commands
FROM python:"$PYTHON_VERSION"-slim as app
# App stage commands
ENTRYPOINT ["app"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment