Skip to content

feat: support container detection #141

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

zAlweNy26
Copy link

Resolves #140

@pi0 is it okay? I also added the wsl and other containers' checks to cover eventually future requests.

Copy link

codecov bot commented Oct 3, 2024

Codecov Report

Attention: Patch coverage is 0% with 76 lines in your changes missing coverage. Please review.

Project coverage is 52.63%. Comparing base (5558f03) to head (a1ff14b).
Report is 6 commits behind head on main.

Files with missing lines Patch % Lines
src/containers/wsl.ts 0.00% 30 Missing and 1 partial ⚠️
src/containers/docker.ts 0.00% 23 Missing and 1 partial ⚠️
src/containers/container.ts 0.00% 17 Missing and 1 partial ⚠️
src/containers/index.ts 0.00% 2 Missing and 1 partial ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##             main     #141       +/-   ##
===========================================
- Coverage   82.08%   52.63%   -29.46%     
===========================================
  Files          10       14        +4     
  Lines         374      285       -89     
  Branches       33       35        +2     
===========================================
- Hits          307      150      -157     
- Misses         61      125       +64     
- Partials        6       10        +4     

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

@pi0
Copy link
Member

pi0 commented Oct 3, 2024

Thanks. Since wsl is not exactly a container (it is VM with dedicated kernel), i would suggest to use /ws and /docker subpaths.

I would love to explore idea of detecting other container runtimes (from cgroups perhaps?) we can iterate later.

@zAlweNy26
Copy link
Author

zAlweNy26 commented Oct 3, 2024

You're right, I just didn't want to make another folder just for that ahah
Anyway okay I'll separate them, should I remove the other container runtimes' checks?
I'll try to add tests for these new flags, hoping not to mess it up ahah

@pi0 pi0 changed the title Support containers flags feat: suport container detection Nov 8, 2024
@pi0
Copy link
Member

pi0 commented Nov 8, 2024

(sorry for late review on this -- it is definitely under my radar)

@zAlweNy26 zAlweNy26 changed the title feat: suport container detection feat: support container detection Nov 8, 2024
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.

Support for containers (docker, etc...)?
2 participants