Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add missing WORKSPACE files to Docker build image for Bazel version detection #954

Merged
merged 1 commit into from
Apr 20, 2022

Conversation

pudelkoM
Copy link
Member

In the current docker builder image bazel(isk) will not pick the Bazel version from the file, because it does not recognize the folder as a Bazel project. This PR fixes this by adding the necessary WORKSPACE and root BUILD files into the container.

Logs from CI run:

Step 31/38 : RUN wget --quiet https://github.com/bazelbuild/bazelisk/releases/download/v${BAZELISK_VERSION}/bazelisk-linux-amd64 &&     mv bazelisk-linux-amd64 /usr/local/bin/bazel &&     chmod +x /usr/local/bin/bazel &&     bazel version
 ---> Running in c25f1a199d1e
2022/03/21 17:11:24 Downloading https://releases.bazel.build/5.0.0/release/bazel-5.0.0-linux-x86_64...
Bazelisk version: v1.8.0
WARNING: Invoking Bazel in batch mode since it is not invoked from within a workspace (below a directory having a WORKSPACE file).
Extracting Bazel installation...
Build label: 5.0.0
Build target: bazel-out/k8-opt/bin/src/main/java/com/google/devtools/build/lib/bazel/BazelServer_deploy.jar
Build time: Wed Jan 19 14:08:54 2022 (1642601334)
Build timestamp: 1642601334
Build timestamp as int: 1642601334

@pudelkoM pudelkoM changed the title Add missing WORKSPACE files to Docker build image for Bazel version detection Add missing WORKSPACE files to Docker build image for Bazel version detection Apr 20, 2022
@pudelkoM
Copy link
Member Author

CI fails because of this issue. Here's a successful publish run: https://app.circleci.com/pipelines/github/stratum/stratum/4489/workflows/ed6f401a-f05f-4f50-8eba-1944a761248c/jobs/29320

@pudelkoM pudelkoM merged commit 12357ef into main Apr 20, 2022
@pudelkoM pudelkoM deleted the docker-build-bazel-version branch April 20, 2022 20:20
ffoulkes added a commit to ipdk-io/stratum-dev that referenced this pull request Jan 18, 2024
)

Signed-off-by: Derek G Foster <derek.foster@intel.com>
ffoulkes added a commit to ipdk-io/stratum-dev that referenced this pull request Jan 18, 2024
)

Signed-off-by: Derek G Foster <derek.foster@intel.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant