Skip to content

chore(devcontainer): consolidate and simplify dev/test/ci envs#3020

Open
solnic wants to merge 10 commits into
masterfrom
chore/devcontainer-no-compose
Open

chore(devcontainer): consolidate and simplify dev/test/ci envs#3020
solnic wants to merge 10 commits into
masterfrom
chore/devcontainer-no-compose

Conversation

@solnic

@solnic solnic commented Jul 13, 2026

Copy link
Copy Markdown
Collaborator

This unifies our dev/test/ci dev container setup:

  • Removes reliance on docker compose - required services now run inside containers, this is just simpler and does not cause port conflicts on dev machines.
  • Uses latest Ubuntu LTS images as the base (and old LTS for Ruby 2.7.
  • Uses mise for Ruby installation exclusively.
  • Uses a custom local dev container feature for installing our entire toolchain (baked into image for faster startups).
  • Drops dependency on playwright (we only used it for chromium installation and its deps, for running e2e specs we actually use Capybara over here).
  • Removes run script as the entrypoint - no longer needed.
  • Adds ci-run as a simpler wrapper script for executing e2e specs on CI.
  • Simplifies devcontainer config by using default workspace dir path.

@solnic solnic changed the title Chore/devcontainer no compose chore(devcontainer): consolidate dev/test/ci envs Jul 13, 2026
@solnic solnic force-pushed the chore/devcontainer-no-compose branch 3 times, most recently from d4384fc to 8d5cf5b Compare July 14, 2026 08:28
@solnic solnic changed the title chore(devcontainer): consolidate dev/test/ci envs chore(devcontainer): consolidate and simplify dev/test/ci envs Jul 14, 2026
@solnic solnic force-pushed the chore/devcontainer-no-compose branch 2 times, most recently from 6d04589 to afebf1f Compare July 14, 2026 11:37
Comment thread .github/workflows/build_images.yml
@solnic solnic force-pushed the chore/devcontainer-no-compose branch from 11ed496 to f3569ab Compare July 14, 2026 12:48
@solnic solnic marked this pull request as ready for review July 14, 2026 13:23

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 2 potential issues.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Want reviews to match your repository better? Bugbot Learning can learn team-specific rules from PR activity. A team admin can enable Learning in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 2a2c499. Configure here.

Comment thread .devcontainer/devcontainer.json
up -d --no-build sentry-test

--env BUNDLE_PATH=/home/sentry/bundle \
--env MISE_RUBY_VERSION=${{ matrix.ruby.version }} \

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

MISE_RUBY_VERSION has no effect

Medium Severity

The e2e workflow passes MISE_RUBY_VERSION into test containers, but nothing in the repo or .mise.toml reads that variable, and the tools feature no longer runs mise use --global for the matrix Ruby. Runtime Ruby stays pinned to .mise.toml's ruby = "latest", so flavor-specific images may not run the intended matrix version.

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 2a2c499. Configure here.

Comment on lines +17 to +19
for directory in bin lib lib32 lib64 libo32 libx32 sbin; do
dpkg-divert --package base-files --no-rename --remove "/${directory}"
done

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Bug: The script's use of dpkg-divert --remove within a loop will cause the build to fail due to set -e when it encounters a directory without a diversion.
Severity: HIGH

Suggested Fix

Modify the dpkg-divert --remove command to handle cases where a diversion does not exist, preventing the script from exiting prematurely. For example, append || true to the command to ensure it doesn't trigger an exit on failure: dpkg-divert ... --remove "/${directory}" || true.

Prompt for AI Agent
Review the code at the location below. A potential bug has been identified by an AI
agent. Verify if this is a real issue. If it is, propose a fix; if not, explain why it's
not valid.

Location: .devcontainer/features/tools/install.sh#L17-L19

Potential issue: The `install.sh` script runs with `set -e`, causing it to exit on any
command failure. It iterates through a list of directories to remove `dpkg-divert`
entries. However, on Ubuntu 24.04, not all of these directories (e.g., `libo32`,
`libx32`) will have an existing diversion. The `dpkg-divert --remove` command returns a
non-zero exit code when a diversion doesn't exist, which triggers the `set -e` trap.
This aborts the script and causes the entire devcontainer build to fail for Ubuntu 24.04
environments.

Did we get this right? 👍 / 👎 to inform future reviews.

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