Skip to content

chore: add autoinstrumentation image for apm-ruby - #315

Merged
xuan-cao-swi merged 3 commits into
mainfrom
autoinstrumentation
Nov 3, 2026
Merged

xuan-cao-swi merged 3 commits into
mainfrom
autoinstrumentation

Conversation

@xuan-cao-swi

Copy link
Copy Markdown
Contributor

Description

Duplicate the autoinstrumentation script from upstream and replace it with apm-ruby.
The workflow will create the image listed in ghcr.io/solarwinds/apm-ruby/autoinstrumentation-ruby.

Test (if applicable)

Tested with latest otel operator release (0.162.0).
Sample trace.

@xuan-cao-swi
xuan-cao-swi marked this pull request as ready for review October 27, 2026 18:06
Copilot AI balanced review requested due to automatic review settings October 27, 2026 18:06
@xuan-cao-swi
xuan-cao-swi requested review from a team as code owners October 27, 2026 18:06

Copilot AI 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.

🟡 Changes recommended

Missing logger load-path support and incompatible native extensions in musl-based containers can prevent instrumentation from initializing.

2 open issues
What changed in this PR

Adds an OpenTelemetry Operator injection image for the SolarWinds APM Ruby gem, enabling Kubernetes auto-instrumentation without adding the agent to application bundles.

Changes:

  • Adds the image build and bootstrap that loads the agent after Bundler.require.
  • Adds a manually triggered, multi-architecture publication workflow using the released gem version.
  • Documents setup and upstream differences, and updates RuboCop CI to Ruby 3.3.
File Description
README.md Introduces Kubernetes auto-instrumentation setup.
docker/​README.md Documents bootstrap behavior and upstream differences.
docker/​Gemfile Selects the released agent gem for the image.
docker/​Dockerfile Builds and packages gems for operator injection.
docker/​autoinstrumentation.rb Injects gem paths and initializes the agent through Bundler.
.github/​workflows/​rubocop-analysis.yml Updates the lint runtime to Ruby 3.3.
.github/​workflows/​publish-autoinstrumentation-ruby.yml Publishes versioned, multi-architecture images to GHCR.

Review effort: Balanced

Comment thread docker/Dockerfile Resolved
Comment thread docker/autoinstrumentation.rb Resolved

@tammy-baylis-swi tammy-baylis-swi 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.

Lgtm

@cheempz cheempz 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.

LGTM, would be good if can be retested with operator instrumentation of an Alpine container app.

@xuan-cao-swi

Copy link
Copy Markdown
Contributor Author

Yeah, tested with operator for alpine build

@xuan-cao-swi
xuan-cao-swi merged commit 19d797b into main Nov 3, 2026
17 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

4 participants