Remove result code check
This commit is contained in:
parent
bbbb57ec06
commit
6faa933d42
@ -85,18 +85,19 @@ def command(ctx, include, exclude):
|
|||||||
print(f"Executing: {build_command}")
|
print(f"Executing: {build_command}")
|
||||||
envs = {"CERC_NPM_AUTH_TOKEN": os.environ["CERC_NPM_AUTH_TOKEN"]} | ({"CERC_SCRIPT_DEBUG": "true"} if debug else {})
|
envs = {"CERC_NPM_AUTH_TOKEN": os.environ["CERC_NPM_AUTH_TOKEN"]} | ({"CERC_SCRIPT_DEBUG": "true"} if debug else {})
|
||||||
try:
|
try:
|
||||||
build_result = docker.run("cerc/builder-js",
|
docker.run("cerc/builder-js",
|
||||||
remove=True,
|
remove=True,
|
||||||
interactive=True,
|
interactive=True,
|
||||||
tty=True,
|
tty=True,
|
||||||
user=f"{os.getuid()}:{os.getgid()}",
|
user=f"{os.getuid()}:{os.getgid()}",
|
||||||
envs=envs,
|
envs=envs,
|
||||||
add_hosts=[("gitea.local", "host-gateway")],
|
add_hosts=[("gitea.local", "host-gateway")],
|
||||||
volumes=[(repo_full_path, "/workspace")],
|
volumes=[(repo_full_path, "/workspace")],
|
||||||
command=build_command
|
command=build_command
|
||||||
)
|
)
|
||||||
# TODO: check result in build_result.returncode
|
# Note that although the docs say that build_result should contain
|
||||||
print(f"Result is: {build_result}")
|
# the command output as a string, in reality it is always the empty string.
|
||||||
|
# Since we detect errors via catching exceptions below, we can safely ignore it here.
|
||||||
except DockerException as e:
|
except DockerException as e:
|
||||||
print(f"FATAL error executing build in container:\n {e}")
|
print(f"FATAL error executing build in container:\n {e}")
|
||||||
else:
|
else:
|
||||||
|
Loading…
Reference in New Issue
Block a user