Skip to content

build: use yq-go (mikefarah) for YAML editing instead of Noble's yq; intro of bbb-yq-go package - #25398

Merged
antobinary merged 10 commits into
bigbluebutton:v4.0.x-developfrom
antobinary:yq-go
Jul 15, 2026
Merged

antobinary merged 10 commits into
bigbluebutton:v4.0.x-developfrom
antobinary:yq-go

Conversation

@antobinary

@antobinary antobinary commented Jul 10, 2026 •

Copy link
Copy Markdown
Member

What this does

BigBlueButton edits its YAML configuration (bbb-conf, package after-install.sh
hooks, systemd units, bbb-install.sh) with mikefarah/yq.
On Ubuntu 24.04 (Noble) the archive yq is instead the kislyuk Python/jq wrapper,
whose YAML writing is not equivalent to mikefarah's. This PR moves everything back onto
mikefarah — invoked as yq-go — and has BigBlueButton ship that tool itself rather
than rely on a third-party PPA.

  • Recover mikefarah syntax — revert kislyuk-era yq -y -i / yq -r / -y -s 'reduce …'
    to yq e -i / yq e … - / eval-all '… ireduce …', and drop the empty-file guards
    kislyuk required. mikefarah writes empty files fine; a guard is kept only in docs where
    the target file may not exist, since mikefarah errors on a missing file.
  • Rename yq → yq-go across config scripts, after-install.sh, systemd units,
    package dependencies and docs. The apt … -yq flags are left untouched (that's -y -q).
  • Add a bbb-yq-go package — build/packages-template/bbb-yq-go repackages mikefarah's
    pinned release binary (checksum-verified) as /usr/bin/yq-go, declaring
    Provides/Conflicts/Replaces yq-go. Built by CI (GitHub + GitLab) and served from
    BigBlueButton's own apt repo.
  • Depend on bbb-yq-go — the packages that use yq now depend on it, so apt installs
    BigBlueButton's own package; it coexists with the archive yq (separate binaries).

Notes

Useful links
https://github.com/mikefarah/yq/releases

Many thanks to @christmart who ported yq-go from Debian into a launchpad ppa. Initially I adopted that ppa but decided it's best for the project to be in control of which yq version we're using.

@coderabbitai

coderabbitai Bot commented Jul 10, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review

Walkthrough

The pull request replaces the legacy yq command with yq-go across installation actions, package builds, configuration orchestration, post-install scripts, LiveKit services, and documentation. It adds packaging support for bbb-yq-go, updates YAML merges, reads, writes, credential extraction, port configuration, and status output, and revises Noble package selections and installation guidance.

Estimated code review effort: 3 (Moderate) | ~30 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Title check ✅ Passed The title clearly summarizes the main change: switching YAML editing to yq-go and introducing the bbb-yq-go package.
Description check ✅ Passed The description is directly related to the changeset and explains the yq-to-yq-go migration and new package.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@antobinary antobinary added this to the Release 4.0 milestone Jul 10, 2026
@antobinary

Copy link
Copy Markdown
Member Author

Note, at time of writing this, yq-go corresponds to yq mikefarah 4.53.2 while on BBB 3.0 we had pinned yq to v4.16.2

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 5

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
docs/docs/administration/customize.md (1)

492-528: 🎯 Functional Correctness | 🟠 Major | ⚡ Quick win

Preserve initialization for empty override files. These standalone yq-go e -i snippets assume /etc/bigbluebutton/bbb-html5.yml already contains valid YAML; if it’s empty, there’s nothing to update. Add a {} bootstrap step or state that the file must exist with valid content first.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@docs/docs/administration/customize.md` around lines 492 - 528, Update the
documented yq-go override commands to handle an empty
`/etc/bigbluebutton/bbb-html5.yml` by adding a `{}` initialization step before
the first update, or explicitly state that the file must already contain valid
YAML; ensure this applies to the standalone commands in the disable settings and
camera profile sections.
🧹 Nitpick comments (1)
bigbluebutton-config/bin/bbb-record (1)

60-60: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low value

--prettyPrint is unnecessary for scalar value extraction.

get_yml_value extracts a single property value. --prettyPrint only affects formatting of complex types (maps/sequences) and is a no-op for scalars. If any caller ever extracts a complex value, the output would differ from the old yq -r raw format. Consider dropping the flag unless you specifically need pretty-printed YAML output for nested values.

♻️ Proposed cleanup
 get_yml_value(){
-   yq-go e ".\"$1\"" "$BBB_YML" --prettyPrint
+   yq-go e ".\"$1\"" "$BBB_YML"
 }
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@bigbluebutton-config/bin/bbb-record` at line 60, Remove the unnecessary
--prettyPrint option from the yq invocation in get_yml_value, preserving raw
scalar extraction behavior and avoiding altered formatting if a complex value is
requested.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In @.github/actions/install-bbb/action.yml:
- Line 158: Revert the temporary installer branch in the wget command to the
stable v4.0.x-release reference, ensuring the install action fetches
bbb-install.sh from the intended release branch rather than
v4.0.x-release-yq-go.

In `@bigbluebutton-config/bin/bbb-conf`:
- Around line 150-173: WEBRTC_SFU_CONFIG is loaded unconditionally, leaving it
empty when the override file is absent. Update the WEBRTC_SFU_CONFIG block to
check WEBRTC_SFU_ETC_CONFIG with an if [ -f ... ] guard, merge both files with
yq-go eval-all when present, and otherwise load WEBRTC_SFU_DEFAULT_CONFIG with
yq-go e, matching the existing WEBRTC_RECORDER_CONFIG, HTML5_CONFIG, and
LIVEKIT_SERVER_CONFIG patterns.

In `@build/packages-template/bbb-livekit/after-install.sh`:
- Around line 24-25: Correct the yq path assignment in the API_SECRET
initialization by changing the expression from `.keys.["$API_KEY"]` to
`.keys["$API_KEY"]`, preserving the existing API_KEY lookup and fallback
behavior.

In `@docs/docs/administration/customize.md`:
- Line 1535: Remove the leading “$” shell prompt marker from the command-only
code block in the documentation, leaving the yq-go command itself unchanged.

In `@docs/docs/development/dev-guide.md`:
- Line 292: Initialize /etc/bigbluebutton/bbb-html5.yml before the yq-go
in-place update, creating the file when absent or empty, then run the existing
yq-go command to set public.kurento.wsUrl.

---

Outside diff comments:
In `@docs/docs/administration/customize.md`:
- Around line 492-528: Update the documented yq-go override commands to handle
an empty `/etc/bigbluebutton/bbb-html5.yml` by adding a `{}` initialization step
before the first update, or explicitly state that the file must already contain
valid YAML; ensure this applies to the standalone commands in the disable
settings and camera profile sections.

---

Nitpick comments:
In `@bigbluebutton-config/bin/bbb-record`:
- Line 60: Remove the unnecessary --prettyPrint option from the yq invocation in
get_yml_value, preserving raw scalar extraction behavior and avoiding altered
formatting if a complex value is requested.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: b868f1d0-24da-4454-8acd-8e136cc8b4b1

📥 Commits

Reviewing files that changed from the base of the PR and between 3cbd010 and 11b03e7.

📒 Files selected for processing (27)
  • .github/actions/install-bbb/action.yml
  • bigbluebutton-config/bin/apply-lib.sh
  • bigbluebutton-config/bin/bbb-conf
  • bigbluebutton-config/bin/bbb-record
  • build/packages-template/bbb-config/after-install.sh
  • build/packages-template/bbb-config/opts-noble.sh
  • build/packages-template/bbb-html5/after-install.sh
  • build/packages-template/bbb-html5/opts-noble.sh
  • build/packages-template/bbb-livekit/after-install.sh
  • build/packages-template/bbb-livekit/livekit-server.service
  • build/packages-template/bbb-livekit/livekit-sip.service
  • build/packages-template/bbb-livekit/opts-noble.sh
  • build/packages-template/bbb-playback-podcast/after-install.sh
  • build/packages-template/bbb-playback-podcast/opts-noble.sh
  • build/packages-template/bbb-playback-presentation/opts-noble.sh
  • build/packages-template/bbb-playback-video/opts-noble.sh
  • build/packages-template/bbb-record-core/after-install.sh
  • build/packages-template/bbb-record-core/opts-noble.sh
  • build/packages-template/bbb-webhooks/after-install.sh
  • build/packages-template/bbb-webhooks/opts-noble.sh
  • build/packages-template/bbb-webrtc-recorder/after-install.sh
  • build/packages-template/bbb-webrtc-recorder/opts-noble.sh
  • build/packages-template/bbb-webrtc-sfu/after-install.sh
  • build/packages-template/bbb-webrtc-sfu/opts-noble.sh
  • docs/docs/administration/customize.md
  • docs/docs/development/dev-guide.md
  • docs/docs/support/troubleshooting.md

Comment thread .github/actions/install-bbb/action.yml Resolved
Comment on lines +150 to +173
WEBRTC_RECORDER_CONFIG=$(yq-go eval-all '. as $item ireduce ({}; . * $item )' $WEBRTC_RECORDER_DEFAULT_CONFIG $WEBRTC_RECORDER_ETC_CONFIG 2> /dev/null)
else
WEBRTC_RECORDER_CONFIG=$(yq -y '.' $WEBRTC_RECORDER_DEFAULT_CONFIG 2> /dev/null)
WEBRTC_RECORDER_CONFIG=$(yq-go e $WEBRTC_RECORDER_DEFAULT_CONFIG 2> /dev/null)
fi

HTML5_DEFAULT_CONFIG=/usr/share/bigbluebutton/html5-client/private/config/settings.yml
HTML5_ETC_CONFIG=/etc/bigbluebutton/bbb-html5.yml
if [ -f $HTML5_ETC_CONFIG ]; then
HTML5_CONFIG=$(yq -y -s 'reduce .[] as $item ({}; . * $item)' $HTML5_DEFAULT_CONFIG $HTML5_ETC_CONFIG 2> /dev/null)
HTML5_CONFIG=$(yq-go eval-all '. as $item ireduce ({}; . * $item )' $HTML5_DEFAULT_CONFIG $HTML5_ETC_CONFIG 2> /dev/null)
else
HTML5_CONFIG=$(yq -y '.' $HTML5_DEFAULT_CONFIG 2> /dev/null)
HTML5_CONFIG=$(yq-go e $HTML5_DEFAULT_CONFIG 2> /dev/null)
fi

mkdir -p /etc/bigbluebutton/bbb-webrtc-sfu
WEBRTC_SFU_DEFAULT_CONFIG=/usr/local/bigbluebutton/bbb-webrtc-sfu/config/default.yml
WEBRTC_SFU_ETC_CONFIG=/etc/bigbluebutton/bbb-webrtc-sfu/production.yml
WEBRTC_SFU_CONFIG=$(yq -y -s 'reduce .[] as $item ({}; . * $item)' $WEBRTC_SFU_DEFAULT_CONFIG $WEBRTC_SFU_ETC_CONFIG 2> /dev/null)
WEBRTC_SFU_CONFIG=$(yq-go eval-all '. as $item ireduce ({}; . * $item )' $WEBRTC_SFU_DEFAULT_CONFIG $WEBRTC_SFU_ETC_CONFIG 2> /dev/null)

LIVEKIT_SERVER_DEFAULT_CONFIG=/usr/share/livekit-server/livekit.yaml
LIVEKIT_SERVER_ETC_CONFIG=/etc/bigbluebutton/livekit.yaml
if [ -f $LIVEKIT_SERVER_ETC_CONFIG ]; then
LIVEKIT_SERVER_CONFIG=$(yq -y -s 'reduce .[] as $item ({}; . * $item)' $LIVEKIT_SERVER_DEFAULT_CONFIG $LIVEKIT_SERVER_ETC_CONFIG 2> /dev/null)
LIVEKIT_SERVER_CONFIG=$(yq-go eval-all '. as $item ireduce ({}; . * $item )' $LIVEKIT_SERVER_DEFAULT_CONFIG $LIVEKIT_SERVER_ETC_CONFIG 2> /dev/null)
else
LIVEKIT_SERVER_CONFIG=$(yq -y '.' $LIVEKIT_SERVER_DEFAULT_CONFIG 2> /dev/null)
LIVEKIT_SERVER_CONFIG=$(yq-go e $LIVEKIT_SERVER_DEFAULT_CONFIG 2> /dev/null)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🩺 Stability & Availability | 🟠 Major | ⚡ Quick win

Add file-existence guard for WEBRTC_SFU_CONFIG loading.

Line 166 unconditionally runs yq-go eval-all with both $WEBRTC_SFU_DEFAULT_CONFIG and $WEBRTC_SFU_ETC_CONFIG, but the other three configs (WEBRTC_RECORDER at lines 148-153, HTML5 at lines 157-161, LIVEKIT_SERVER at lines 170-173) all guard with if [ -f $ETC_CONFIG ] and fall back to yq-go e $DEFAULT_CONFIG when the override file is absent. If /etc/bigbluebutton/bbb-webrtc-sfu/production.yml doesn't exist (e.g., fresh install before bbb-conf --setip), eval-all will fail, 2>/dev/null suppresses the error, and WEBRTC_SFU_CONFIG is left empty — causing blank SFU values in --check/--status output and a spurious SIP IP mismatch warning at lines 1100-1113.

🔧 Proposed fix: add the same guard used by the other configs
 mkdir -p /etc/bigbluebutton/bbb-webrtc-sfu
 WEBRTC_SFU_DEFAULT_CONFIG=/usr/local/bigbluebutton/bbb-webrtc-sfu/config/default.yml
 WEBRTC_SFU_ETC_CONFIG=/etc/bigbluebutton/bbb-webrtc-sfu/production.yml
-WEBRTC_SFU_CONFIG=$(yq-go eval-all '. as $item ireduce ({}; . * $item )' $WEBRTC_SFU_DEFAULT_CONFIG $WEBRTC_SFU_ETC_CONFIG 2> /dev/null)
+if [ -f $WEBRTC_SFU_ETC_CONFIG ]; then
+    WEBRTC_SFU_CONFIG=$(yq-go eval-all '. as $item ireduce ({}; . * $item )' $WEBRTC_SFU_DEFAULT_CONFIG $WEBRTC_SFU_ETC_CONFIG 2> /dev/null)
+else
+    WEBRTC_SFU_CONFIG=$(yq-go e $WEBRTC_SFU_DEFAULT_CONFIG 2> /dev/null)
+fi
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
WEBRTC_RECORDER_CONFIG=$(yq-go eval-all '. as $item ireduce ({}; . * $item )' $WEBRTC_RECORDER_DEFAULT_CONFIG $WEBRTC_RECORDER_ETC_CONFIG 2> /dev/null)
else
WEBRTC_RECORDER_CONFIG=$(yq -y '.' $WEBRTC_RECORDER_DEFAULT_CONFIG 2> /dev/null)
WEBRTC_RECORDER_CONFIG=$(yq-go e $WEBRTC_RECORDER_DEFAULT_CONFIG 2> /dev/null)
fi
HTML5_DEFAULT_CONFIG=/usr/share/bigbluebutton/html5-client/private/config/settings.yml
HTML5_ETC_CONFIG=/etc/bigbluebutton/bbb-html5.yml
if [ -f $HTML5_ETC_CONFIG ]; then
HTML5_CONFIG=$(yq -y -s 'reduce .[] as $item ({}; . * $item)' $HTML5_DEFAULT_CONFIG $HTML5_ETC_CONFIG 2> /dev/null)
HTML5_CONFIG=$(yq-go eval-all '. as $item ireduce ({}; . * $item )' $HTML5_DEFAULT_CONFIG $HTML5_ETC_CONFIG 2> /dev/null)
else
HTML5_CONFIG=$(yq -y '.' $HTML5_DEFAULT_CONFIG 2> /dev/null)
HTML5_CONFIG=$(yq-go e $HTML5_DEFAULT_CONFIG 2> /dev/null)
fi
mkdir -p /etc/bigbluebutton/bbb-webrtc-sfu
WEBRTC_SFU_DEFAULT_CONFIG=/usr/local/bigbluebutton/bbb-webrtc-sfu/config/default.yml
WEBRTC_SFU_ETC_CONFIG=/etc/bigbluebutton/bbb-webrtc-sfu/production.yml
WEBRTC_SFU_CONFIG=$(yq -y -s 'reduce .[] as $item ({}; . * $item)' $WEBRTC_SFU_DEFAULT_CONFIG $WEBRTC_SFU_ETC_CONFIG 2> /dev/null)
WEBRTC_SFU_CONFIG=$(yq-go eval-all '. as $item ireduce ({}; . * $item )' $WEBRTC_SFU_DEFAULT_CONFIG $WEBRTC_SFU_ETC_CONFIG 2> /dev/null)
LIVEKIT_SERVER_DEFAULT_CONFIG=/usr/share/livekit-server/livekit.yaml
LIVEKIT_SERVER_ETC_CONFIG=/etc/bigbluebutton/livekit.yaml
if [ -f $LIVEKIT_SERVER_ETC_CONFIG ]; then
LIVEKIT_SERVER_CONFIG=$(yq -y -s 'reduce .[] as $item ({}; . * $item)' $LIVEKIT_SERVER_DEFAULT_CONFIG $LIVEKIT_SERVER_ETC_CONFIG 2> /dev/null)
LIVEKIT_SERVER_CONFIG=$(yq-go eval-all '. as $item ireduce ({}; . * $item )' $LIVEKIT_SERVER_DEFAULT_CONFIG $LIVEKIT_SERVER_ETC_CONFIG 2> /dev/null)
else
LIVEKIT_SERVER_CONFIG=$(yq -y '.' $LIVEKIT_SERVER_DEFAULT_CONFIG 2> /dev/null)
LIVEKIT_SERVER_CONFIG=$(yq-go e $LIVEKIT_SERVER_DEFAULT_CONFIG 2> /dev/null)
WEBRTC_RECORDER_CONFIG=$(yq-go eval-all '. as $item ireduce ({}; . * $item )' $WEBRTC_RECORDER_DEFAULT_CONFIG $WEBRTC_RECORDER_ETC_CONFIG 2> /dev/null)
else
WEBRTC_RECORDER_CONFIG=$(yq-go e $WEBRTC_RECORDER_DEFAULT_CONFIG 2> /dev/null)
fi
HTML5_DEFAULT_CONFIG=/usr/share/bigbluebutton/html5-client/private/config/settings.yml
HTML5_ETC_CONFIG=/etc/bigbluebutton/bbb-html5.yml
if [ -f $HTML5_ETC_CONFIG ]; then
HTML5_CONFIG=$(yq-go eval-all '. as $item ireduce ({}; . * $item )' $HTML5_DEFAULT_CONFIG $HTML5_ETC_CONFIG 2> /dev/null)
else
HTML5_CONFIG=$(yq-go e $HTML5_DEFAULT_CONFIG 2> /dev/null)
fi
mkdir -p /etc/bigbluebutton/bbb-webrtc-sfu
WEBRTC_SFU_DEFAULT_CONFIG=/usr/local/bigbluebutton/bbb-webrtc-sfu/config/default.yml
WEBRTC_SFU_ETC_CONFIG=/etc/bigbluebutton/bbb-webrtc-sfu/production.yml
if [ -f $WEBRTC_SFU_ETC_CONFIG ]; then
WEBRTC_SFU_CONFIG=$(yq-go eval-all '. as $item ireduce ({}; . * $item )' $WEBRTC_SFU_DEFAULT_CONFIG $WEBRTC_SFU_ETC_CONFIG 2> /dev/null)
else
WEBRTC_SFU_CONFIG=$(yq-go e $WEBRTC_SFU_DEFAULT_CONFIG 2> /dev/null)
fi
LIVEKIT_SERVER_DEFAULT_CONFIG=/usr/share/livekit-server/livekit.yaml
LIVEKIT_SERVER_ETC_CONFIG=/etc/bigbluebutton/livekit.yaml
if [ -f $LIVEKIT_SERVER_ETC_CONFIG ]; then
LIVEKIT_SERVER_CONFIG=$(yq-go eval-all '. as $item ireduce ({}; . * $item )' $LIVEKIT_SERVER_DEFAULT_CONFIG $LIVEKIT_SERVER_ETC_CONFIG 2> /dev/null)
else
LIVEKIT_SERVER_CONFIG=$(yq-go e $LIVEKIT_SERVER_DEFAULT_CONFIG 2> /dev/null)
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@bigbluebutton-config/bin/bbb-conf` around lines 150 - 173, WEBRTC_SFU_CONFIG
is loaded unconditionally, leaving it empty when the override file is absent.
Update the WEBRTC_SFU_CONFIG block to check WEBRTC_SFU_ETC_CONFIG with an if [
-f ... ] guard, merge both files with yq-go eval-all when present, and otherwise
load WEBRTC_SFU_DEFAULT_CONFIG with yq-go e, matching the existing
WEBRTC_RECORDER_CONFIG, HTML5_CONFIG, and LIVEKIT_SERVER_CONFIG patterns.

Comment on lines +24 to +25
API_KEY=${API_KEY:-$(yq-go e '.webhook.api_key' /etc/bigbluebutton/livekit.yaml)}
API_SECRET=${API_SECRET:-$(yq-go e ".keys.[\"$API_KEY\"]" /etc/bigbluebutton/livekit.yaml)}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟠 Major | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Description: Verify whether mikefarah yq-go accepts .keys.["key"] dot-before-bracket syntax.
# Requires yq-go to be installed. If not available, check yq-go version and docs.

# Check if yq-go is available
if command -v yq-go &>/dev/null; then
  yq-go --version
  
  # Create a test YAML file
  cat > /tmp/test_keys.yaml << 'EOF'
keys:
  abc123: def456
webhook:
  api_key: abc123
EOF

  echo "Testing .keys[\"abc123\"] (no dot before bracket):"
  yq-go e '.keys["abc123"]' /tmp/test_keys.yaml 2>&1 || echo "FAILED with exit code $?"
  
  echo ""
  echo "Testing .keys.[\"abc123\"] (dot before bracket):"
  yq-go e '.keys.["abc123"]' /tmp/test_keys.yaml 2>&1 || echo "FAILED with exit code $?"
  
  rm -f /tmp/test_keys.yaml
else
  echo "yq-go not installed in sandbox. Please verify on a Noble system with yq-go installed."
  echo "Check yq-go version: yq-go --version"
  echo "Test both syntaxes:"
  echo '  yq-go e '\''.keys["abc123"]'\'' test.yaml'
  echo '  yq-go e '\''.keys.["abc123"]'\'' test.yaml'
fi

Repository: bigbluebutton/bigbluebutton

Length of output: 1972


🌐 Web query:

mikefarah yq v4 bracket syntax .keys["key"] .keys.["key"] documentation

💡 Result:

In mikefarah/yq v4, the correct and standard syntax for accessing keys is.["key"] [1][2]. The syntax.keys.["key"] is generally incorrect because the dot operator must be followed by a key name or specific expression, and placing a dot before the bracketed index operator is not the standard way to traverse map or object keys [1][2][3]. Key points regarding bracket syntax: 1. Standard Access: To access a key—especially one containing special characters (like dots or spaces)—use the bracket syntax immediately after the parent object, such as.parent.["key.name"] or.["key with spaces"] [1][2][3]. 2. Purpose of Brackets: Brackets are used to handle keys that cannot be addressed via simple dot notation (e.g.,.key), specifically those with special characters [1][2][3]. 3. Avoiding the Extra Dot: Using.["key"] is valid when following an object, but do not insert a dot between the object reference and the opening bracket (i.e., avoid.["key"] if you are trying to chain it to a previous path component unless that component is a terminal object that supports indexing) [1][2]. If you are experiencing issues with paths, ensure you are not using a leading dot before the bracket if it is intended to act as the primary accessor for that level, or ensure that if you are traversing, the path is fully qualified [1][2]. For example, use.myMap["my.key"] rather than.myMap.["my.key"] [1][3].

Citations:


Drop the extra dot before the bracket. build/packages-template/bbb-livekit/after-install.sh:25 should use .keys["$API_KEY"]; .keys.["$API_KEY"] is not valid mikefarah/yq v4 syntax and can leave API_SECRET empty.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@build/packages-template/bbb-livekit/after-install.sh` around lines 24 - 25,
Correct the yq path assignment in the API_SECRET initialization by changing the
expression from `.keys.["$API_KEY"]` to `.keys["$API_KEY"]`, preserving the
existing API_KEY lookup and fallback behavior.

Comment thread docs/docs/administration/customize.md Resolved
Comment thread docs/docs/development/dev-guide.md Resolved

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
docs/docs/administration/customize.md (1)

1629-1638: 🔒 Security & Privacy | 🟠 Major | ⚡ Quick win

Configure the BBB 3.0+ API key in the controller .env file.

This section first writes x_gladia_key to config/default.yml, then replaces startMessage with a keyless payload for BBB 3.0+. For BBB 3.0+ with controller versions greater than 0.3.x, instruct users to set the key in the transcription controller’s .env file and keep only audio parameters in startMessage; reserve the current YAML payload for older versions.

Based on learnings, BBB 3.0+ requires the Gladia API key in the controller .env file and must not include it in gladia.startMessage.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@docs/docs/administration/customize.md` around lines 1629 - 1638, Update the
Gladia configuration section to distinguish controller versions: for BBB 3.0+
with bbb-transcription-controller versions greater than 0.3.x, instruct users to
configure the Gladia API key in the controller’s .env file and keep
gladia.startMessage limited to audio parameters; reserve the YAML payload
containing x_gladia_key for older versions.

Source: Learnings

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Outside diff comments:
In `@docs/docs/administration/customize.md`:
- Around line 1629-1638: Update the Gladia configuration section to distinguish
controller versions: for BBB 3.0+ with bbb-transcription-controller versions
greater than 0.3.x, instruct users to configure the Gladia API key in the
controller’s .env file and keep gladia.startMessage limited to audio parameters;
reserve the YAML payload containing x_gladia_key for older versions.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: 97cde2de-5e30-4280-982e-8af97225c8f0

📥 Commits

Reviewing files that changed from the base of the PR and between 11b03e7 and a8aa179.

📒 Files selected for processing (2)
  • docs/docs/administration/customize.md
  • docs/docs/development/dev-guide.md
✅ Files skipped from review due to trivial changes (1)
  • docs/docs/development/dev-guide.md

BBB 4.0 edits its YAML config with mikefarah's Go yq. On Ubuntu 24.04 the
archive `yq` is the kislyuk Python tool, so BBB invokes the mikefarah binary
under the distinct name `yq-go`. Packaging it here builds and ships it from
BBB's own apt repo instead of relying on a third-party PPA.

Adds build/packages-template/bbb-yq-go/ (following the bbb-mkclean pattern):
- build.sh downloads the pinned upstream release binary (YQ_VERSION=4.53.2,
  amd64), verifies it against bbb-yq-go.sha256sum, installs it as
  /usr/bin/yq-go, and fpm-packages it.
- The .deb declares Provides/Conflicts/Replaces yq-go, making it a drop-in for
  the martin-uni-mainz PPA's yq-go and satisfying any `yq-go` dependency.
- opts-noble.sh sources the global fpm opts (vendor/maintainer/url).
- Registered in package-names.inc.sh as do_not_copy_anything so CI builds it.
@sonarqubecloud

Copy link
Copy Markdown

@antobinary antobinary changed the title refactor: use yq-go (mikefarah) for YAML editing instead of Noble's yq build: use yq-go (mikefarah) for YAML editing instead of Noble's yq; intro of bbb-yq-go package Jul 15, 2026
@github-actions

Copy link
Copy Markdown

✅ Automated tests have passed!

@antobinary
antobinary merged commit ce1e000 into bigbluebutton:v4.0.x-develop Jul 15, 2026
35 checks passed
@antobinary
antobinary deleted the yq-go branch July 15, 2026 17:01
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.

1 participant