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

pkg/{cgroups,topology}: move linux-specific functions #328

Merged
merged 1 commit into from
Jun 18, 2024

Conversation

elezar
Copy link
Contributor

@elezar elezar commented Jun 7, 2024

This change moves linux-specific functions to _linux.go source files and adds stub implementations for other platforms.

@klihub klihub requested review from kad and askervin June 10, 2024 06:49
@@ -0,0 +1,12 @@
package cgroups

import "encoding/binary"
Copy link
Collaborator

Choose a reason for hiding this comment

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

missing import "golang.org/x/sys/unix".

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes, you're right. I was building locally on a darwin machine. Let me do so in a container too.

This change moves linux specific functions to _linux.go files.
This enables basic builds and tests on other platforms.

Signed-off-by: Evan Lezar <elezar@nvidia.com>
@elezar elezar requested a review from askervin June 10, 2024 11:07
@klihub klihub changed the title Move linux-specific functions pkg/{cgroups,topology}: move linux-specific functions Jun 18, 2024
Copy link
Collaborator

@klihub klihub left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Collaborator

@askervin askervin left a comment

Choose a reason for hiding this comment

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

LGTM

@askervin askervin merged commit 8fc559b into containers:main Jun 18, 2024
2 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.

3 participants