Skip to content

bazel: add Bazel equivalent of make codebeamer-pem - #617

Open
NikitaJangidBMW wants to merge 1 commit into
mainfrom
internal/replace-make-with-bazel-target-in-lobster
Open

bazel: add Bazel equivalent of make codebeamer-pem#617
NikitaJangidBMW wants to merge 1 commit into
mainfrom
internal/replace-make-with-bazel-target-in-lobster

Conversation

@NikitaJangidBMW

@NikitaJangidBMW NikitaJangidBMW commented Jul 24, 2026

Copy link
Copy Markdown
Contributor

Bazel equivalent of make codebeamer-pem. Adds a custom generate_certs
rule that generates self-signed SSL certificates for the codebeamer mock
server, following the existing repo pattern (ctx.actions.run_shell).

Files changed

  • bazel/private/generate_certs.bzl — new custom Starlark rule using system openssl
  • tests_system/lobster_codebeamer/data/BUILD.bazelcodebeamer_pem target
  • tests_system/lobster_codebeamer/mock_server.py — fix cert path resolution for Bazel runfiles
  • lobster.bzl — export generate_certs
  • documentation/manual-lobster_codebeamer.md — document make and Bazel commands for SSL cert generation
  • .bazelrc — replace deprecated --experimental_enable_bzlmod with --enable_bzlmod
  • tests_system/README.md — fix typo: Pyton → Python

How to test

bazel test //tests_system/lobster_codebeamer:test_lobster_codebeamer

NOTE:

mock_server.py - Dual cert path support (temporary)

Added runtime fallback logic to support both build systems during the migration period:

Bazel: certificates are generated by the codebeamer_pem target and placed flat in data/cert.pem / data/key.pem
Make: certificates are generated by make codebeamer-pem and placed in data/ssl/cert.pem / data/ssl/key.pem

The server checks for the Bazel path first and falls back to the Make path. Once make system-tests is fully replaced by bazel test //tests_system:system_tests, the Make fallback (data/ssl/ path) can be removed and only the Bazel path will remain.

@NikitaJangidBMW
NikitaJangidBMW requested a review from a team as a code owner July 24, 2026 04:15
@NikitaJangidBMW
NikitaJangidBMW force-pushed the internal/replace-make-with-bazel-target-in-lobster branch from 6b0c642 to 9556625 Compare July 24, 2026 05:20
@NikitaJangidBMW NikitaJangidBMW added the internal Affects the CI, tests or refactorings only, not relevant to the end-user label Jul 28, 2026
@NikitaJangidBMW
NikitaJangidBMW force-pushed the internal/replace-make-with-bazel-target-in-lobster branch from d0d33f5 to 3879a01 Compare August 12, 2026 10:50
Add generate_certs Starlark rule to generate SSL certs via system openssl, with codebeamer_pem target wired into test data.
@NikitaJangidBMW
NikitaJangidBMW force-pushed the internal/replace-make-with-bazel-target-in-lobster branch from 3879a01 to de424bc Compare August 12, 2026 10:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bazel internal Affects the CI, tests or refactorings only, not relevant to the end-user

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant