Skip to content

Commit 1ba68e0

Browse files
authored
fix: Merge command line args with the ones in the config file (#5317)
* fix: Merge command line args with the ones in the config file Signed-off-by: Frost Ming <me@frostming.com>
1 parent 316d60c commit 1ba68e0

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/bentoml/_internal/bento/build_config.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@
2424
from ..configuration import get_bentoml_requirement
2525
from ..configuration import get_debug_mode
2626
from ..configuration import get_quiet_mode
27+
from ..configuration.containers import BentoMLContainer
2728
from ..container import generate_containerfile
2829
from ..container.frontend.dockerfile import ALLOWED_CUDA_VERSION_ARGS
2930
from ..container.frontend.dockerfile import CONTAINER_SUPPORTED_DISTROS
@@ -886,7 +887,9 @@ def __attrs_post_init__(self) -> None:
886887
)
887888

888889
if self.args:
889-
set_arguments(**self.args)
890+
# Merge command line args with the ones in the config file
891+
# and the command line args take precedence
892+
set_arguments(**self.args, **BentoMLContainer.bento_arguments.get())
890893

891894
def with_defaults(self) -> FilledBentoBuildConfig:
892895
"""

0 commit comments

Comments
 (0)