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

Create directories with 700 and not 644 #154

Merged
merged 1 commit into from
Dec 14, 2024

Conversation

adrianreber
Copy link
Member

@adrianreber adrianreber commented Dec 14, 2024

checkpointctl was creating directories with 644 which broke usage when running as non-root as checkpointctl was not able to access the directories it created itself. Switching to 700 fixes it.

This comes with a test to verify that checkpointctl works as non-root.

Fixes: #153

@codecov-commenter
Copy link

codecov-commenter commented Dec 14, 2024

Codecov Report

Attention: Patch coverage is 0% with 1 line in your changes missing coverage. Please review.

Project coverage is 76.42%. Comparing base (8a3ffb9) to head (da73a77).

Files with missing lines Patch % Lines
internal/container.go 0.00% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main     #154   +/-   ##
=======================================
  Coverage   76.42%   76.42%           
=======================================
  Files          11       11           
  Lines        1442     1442           
=======================================
  Hits         1102     1102           
  Misses        266      266           
  Partials       74       74           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link

github-actions bot commented Dec 14, 2024

Test Results

61 tests  +1   61 ✅ +1   2s ⏱️ -1s
 1 suites ±0    0 💤 ±0 
 1 files   ±0    0 ❌ ±0 

Results for commit da73a77. ± Comparison against base commit 8a3ffb9.

♻️ This comment has been updated with latest results.

@adrianreber adrianreber force-pushed the 2024-12-14-755 branch 3 times, most recently from 9281ecc to 5666a4c Compare December 14, 2024 10:03
checkpointctl was creating directories with 644 which broke usage when
running as non-root as checkpointctl was not able to access the
directories it created itself. Switching to 700 fixes it.

This comes with a test to verify that checkpointctl works as non-root.

Signed-off-by: Adrian Reber <[email protected]>
@adrianreber adrianreber changed the title Create directories with 755 and not 644 Create directories with 700 and not 644 Dec 14, 2024
Copy link
Member

@rst0git rst0git left a comment

Choose a reason for hiding this comment

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

LGTM

@rst0git rst0git merged commit 15dd6b5 into checkpoint-restore:main Dec 14, 2024
10 checks passed
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.

No executable bit on the checkpoint directory
3 participants