Skip to content
Snippets Groups Projects
Commit 0ea60be9 authored by Vincent Hatakeyama's avatar Vincent Hatakeyama
Browse files

:ambulance: Remove buildx test and use of buildx

parent 242bd882
No related branches found
No related tags found
No related merge requests found
...@@ -2,6 +2,11 @@ ...@@ -2,6 +2,11 @@
History History
======= =======
21.0.5
------
Avoid docker.buildx.is_installed() as it reports installation even if it is not installed.
21.0.4 21.0.4
------ ------
......
...@@ -22,5 +22,5 @@ ...@@ -22,5 +22,5 @@
_logger = logging.getLogger(__name__) _logger = logging.getLogger(__name__)
__version__ = "1.6.0" __version__ = "1.6.1"
__date__ = "2018-04-04" __date__ = "2018-04-04"
...@@ -26,5 +26,5 @@ ...@@ -26,5 +26,5 @@
__date__ = "2018-04-04" __date__ = "2018-04-04"
__updated__ = "2023-10-31" __updated__ = "2023-11-16"
def add_build_options(parser: argparse.ArgumentParser): def add_build_options(parser: argparse.ArgumentParser):
...@@ -250,23 +250,13 @@ ...@@ -250,23 +250,13 @@
_logger.debug("Docker Pull %s", pull) _logger.debug("Docker Pull %s", pull)
full_tags = [repository] if nmspc.local else [f"{repository}:{tag}" for tag in tags] full_tags = [repository] if nmspc.local else [f"{repository}:{tag}" for tag in tags]
with capture_docker_exit_code() as exit_code: with capture_docker_exit_code() as exit_code:
if docker.buildx.is_installed(): docker.image.build(
_logger.info("Starting build with buildx") context_path=".",
docker.buildx.build( pull=pull,
context_path=".", build_args=buildargs,
pull=pull, tags=full_tags,
build_args=buildargs, file=dockerfile,
tags=full_tags, )
file=dockerfile,
)
else:
docker.image.build(
context_path=".",
pull=pull,
build_args=buildargs,
tags=full_tags,
file=dockerfile,
)
if dev: if dev:
call(["rm", dockerfile]) call(["rm", dockerfile])
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment