From b3323cd058c0f801d59907a4acc4dfade8a77da4 Mon Sep 17 00:00:00 2001 From: unclejack Date: Thu, 20 Feb 2014 17:16:45 +0200 Subject: [PATCH] forbid chained onbuild, from & maintainer triggers This changes the way onbuild works: - forbids the chaining of onbuild instructions - forbids the use of `onbuild from` - forbids the use of `onbuild maintainer` It also makes docker throw errors when encountering such triggers when executing the triggers during `FROM`. Three tests have been added: - ensure that chained onbuild (`onbuild onbuild`) is forbidden - ensure that `onbuild from` is forbidden - ensure that `onbuild maintainer` is forbidden Docker-DCO-1.1-Signed-off-by: Cristian Staretu (github: unclejack) Upstream-commit: a79fae655d989595ed2345425632768a157a7e54 Component: cli --- components/cli/docs/sources/reference/builder.rst | 2 ++ 1 file changed, 2 insertions(+) diff --git a/components/cli/docs/sources/reference/builder.rst b/components/cli/docs/sources/reference/builder.rst index 4b6a151006..6fabd6629d 100644 --- a/components/cli/docs/sources/reference/builder.rst +++ b/components/cli/docs/sources/reference/builder.rst @@ -466,6 +466,8 @@ For example you might add something like this: ONBUILD RUN /usr/local/bin/python-build --dir /app/src [...] +.. warning:: Chaining ONBUILD instructions using `ONBUILD ONBUILD` isn't allowed. +.. warning:: ONBUILD may not trigger FROM or MAINTAINER instructions. .. _dockerfile_examples: