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

Reapply "[image-builder-bob] bump up buildkit (#20690)" (#20693) #20694

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

iQQBot
Copy link
Contributor

@iQQBot iQQBot commented Mar 21, 2025

This reverts commit 7137833.

Tool: gitpod/catfood.gitpod.cloud

Description

This pid is actually thread id, it should be safe if we use in thread-self

see doc link
image

workspace integration test are success https://github.com/gitpod-io/gitpod/actions/runs/13993623337/job/39183946713?pr=20694

Related Issue(s)

Fixes CLC-1252

How to test

Documentation

Preview status

Gitpod was successfully deployed to your preview environment.

Build Options

Build
  • /werft with-werft
    Run the build with werft instead of GHA
  • leeway-no-cache
  • /werft no-test
    Run Leeway with --dont-test
Publish
  • /werft publish-to-npm
  • /werft publish-to-jb-marketplace
Installer
  • analytics=segment
  • with-dedicated-emulation
  • workspace-feature-flags
    Add desired feature flags to the end of the line above, space separated
Preview Environment / Integration Tests
  • /werft with-local-preview
    If enabled this will build install/preview
  • /werft with-preview
  • /werft with-large-vm
  • /werft with-gce-vm
    If enabled this will create the environment on GCE infra
  • /werft preemptible
    Saves cost. Untick this only if you're really sure you need a non-preemtible machine.
  • with-integration-tests=all
    Valid options are all, workspace, webapp, ide, jetbrains, vscode, ssh. If enabled, with-preview and with-large-vm will be enabled.
  • with-monitoring

/hold

iQQBot added 2 commits March 21, 2025 14:08
This reverts commit 7137833.

Tool: gitpod/catfood.gitpod.cloud
Tool: gitpod/catfood.gitpod.cloud
@iQQBot iQQBot force-pushed the pd/upgrade-buildkit branch from d5d1291 to b568af2 Compare March 21, 2025 14:08
@roboquat roboquat added size/S and removed size/XS labels Mar 21, 2025
@iQQBot iQQBot marked this pull request as ready for review March 21, 2025 14:29
@iQQBot iQQBot requested review from a team as code owners March 21, 2025 14:29
Copy link
Contributor

@kylos101 kylos101 left a comment

Choose a reason for hiding this comment

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

👋 @iQQBot , nice find! It would be good to get a review from a SME for workspacekit

Comment on lines +278 to +280
if strings.HasPrefix(dest, "/proc/thread-self/") {
target = filepath.Join("/proc", strconv.Itoa(int(req.Pid)), strings.TrimPrefix(dest, "/proc/thread-self/"))
}
Copy link
Contributor

Choose a reason for hiding this comment

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

How does this change impact regular workspaces, and prebuilds?

Copy link
Contributor

Choose a reason for hiding this comment

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

I see tests were failing, and assume this is the intended fix:

--- FAIL: TestBaseImageBuild (50.03s)
--- FAIL: TestBaseImageBuild/database (0.00s)
--- FAIL: TestBaseImageBuild/database/it_should_build_a_base_image (50.03s)

--- FAIL: TestParallelBaseImageBuild (28.78s)
--- FAIL: TestParallelBaseImageBuild/image-builder (0.00s)
--- FAIL: TestParallelBaseImageBuild/image-builder/it_should_allow_parallel_build_of_images (28.78s)

Copy link
Contributor

Choose a reason for hiding this comment

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

It would be good, I think, to get a review for this file from @Furisto @aledbf or @csweichel .

Copy link
Contributor Author

Choose a reason for hiding this comment

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

We previously did not handle thread-self, so it would fallback to nsenter, using the tid/pid of nsenter at that time. Handling it here actually increases some security.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants