bazelbuild / rules_docker

Rules for building and handling Docker images with Bazel

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Dockerfile_build timed out issue

lhviet opened this issue Β· comments

🐞 bug report

Hi, when trying to build a Dockerfile with Bazel, I encounter the issue of Time out.

Affected Rule

https://github.com/bazelbuild/rules_docker/blob/master/contrib/dockerfile_build.bzl#L64-L76

Is this a regression?

N/A

Description

ERROR: An error occurred during the fetch of repository 'opencti-platform-image':
Traceback (most recent call last):
File "/home/runner/.cache/bazel/_bazel_runner/d8466fb45ee98180472924375306ec29/external/io_bazel_rules_docker/contrib/dockerfile_build.bzl", line 83, column 13, in _impl
fail("docker build command failed: {} ({})".format(
Error in fail: docker build command failed: Timed out (/usr/bin/docker build --no-cache -f /home/runner/work/opencti/opencti/opencti/opencti-platform/Dockerfile -t opencti-platform-image:dockerfile_image /home/runner/work/opencti/opencti/opencti/opencti-platform)
ERROR: /home/runner/work/opencti/opencti/WORKSPACE:113:17: fetching dockerfile_image rule //external:opencti-platform-image: Traceback (most recent call last):
File "/home/runner/.cache/bazel/_bazel_runner/d8466fb45ee98180472924375306ec29/external/io_bazel_rules_docker/contrib/dockerfile_build.bzl", line 83, column 13, in _impl
fail("docker build command failed: {} ({})".format(
Error in fail: docker build command failed: Timed out (/usr/bin/docker build --no-cache -f /home/runner/work/opencti/opencti/opencti/opencti-platform/Dockerfile -t opencti-platform-image:dockerfile_image /home/runner/work/opencti/opencti/opencti/opencti-platform)
ERROR: /home/runner/work/opencti/opencti/opencti/BUILD.bazel:17:16: //opencti:opencti-platform-image depends on @opencti-platform-image//image:dockerfile_image.tar in repository @opencti-platform-image which failed to fetch. no such package '@opencti-platform-image//image': docker build command failed: Timed out (/usr/bin/docker build --no-cache -f /home/runner/work/opencti/opencti/opencti/opencti-platform/Dockerfile -t opencti-platform-image:dockerfile_image /home/runner/work/opencti/opencti/opencti/opencti-platform)
ERROR: Analysis of target '//opencti:all_prod_images' failed; build aborted:
INFO: Elapsed time: 623.601s

This issue has been automatically marked as stale because it has not had any activity for 180 days. It will be closed if no further activity occurs in 30 days.
Collaborators can add an assignee to keep this open indefinitely. Thanks for your contributions to rules_docker!

I have came across the same issue...