Do not allow to specify both image and dockerfile in configuration. Closes #1908
Signed-off-by: Karol Duleba <mr.fuxi@gmail.com>
This commit is contained in:
parent
ecd1cc31dc
commit
477d4f491d
4 changed files with 26 additions and 1 deletions
|
|
@ -134,6 +134,11 @@ def process_errors(errors):
|
|||
required.append(
|
||||
"Service '{}' has neither an image nor a build path "
|
||||
"specified. Exactly one must be provided.".format(service_name))
|
||||
elif 'image' in error.instance and 'dockerfile' in error.instance:
|
||||
required.append(
|
||||
"Service '{}' has both an image and alternate Dockerfile. "
|
||||
"A service can either be built to image or use an existing "
|
||||
"image, not both.".format(service_name))
|
||||
else:
|
||||
required.append(_clean_error_message(error.message))
|
||||
elif error.validator == 'oneOf':
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue