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

Project does not build when GOOS=darwin #1556

Open
wmedlar opened this issue Apr 3, 2023 · 7 comments
Open

Project does not build when GOOS=darwin #1556

wmedlar opened this issue Apr 3, 2023 · 7 comments
Labels
kind/bug Categorizes issue or PR as related to a bug. lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale.

Comments

@wmedlar
Copy link

wmedlar commented Apr 3, 2023

/kind bug

What happened?

The project does not compile on MacOS / darwin because there is no code to implement the necessary nodeService methods like there is for Linux and Windows.

What you expected to happen?

Code compiles well enough to run e2e tests.

How to reproduce it (as minimally and precisely as possible)?

$ GOOS=darwin go build -o bin/aws-ebs-csi-driver ./cmd/
# github.com/kubernetes-sigs/aws-ebs-csi-driver/pkg/driver
pkg/driver/mount.go:63:9: cannot use &NodeMounter{…} (value of type *NodeMounter) as Mounter value in return statement: *NodeMounter does not implement Mounter (missing method GetDeviceNameFromMount)
pkg/driver/node.go:190:19: d.findDevicePath undefined (type *nodeService has no field or method findDevicePath)
pkg/driver/node.go:340:21: d.IsBlockDevice undefined (type *nodeService has no field or method IsBlockDevice)
pkg/driver/node.go:346:19: d.getBlockSizeBytes undefined (type *nodeService has no field or method getBlockSizeBytes)
pkg/driver/node.go:360:23: d.findDevicePath undefined (type *nodeService has no field or method findDevicePath)
pkg/driver/node.go:375:17: d.getBlockSizeBytes undefined (type *nodeService has no field or method getBlockSizeBytes)
pkg/driver/node.go:480:20: d.IsBlockDevice undefined (type *nodeService has no field or method IsBlockDevice)
pkg/driver/node.go:486:23: d.getBlockSizeBytes undefined (type *nodeService has no field or method getBlockSizeBytes)
pkg/driver/node.go:592:19: d.findDevicePath undefined (type *nodeService has no field or method findDevicePath)
pkg/driver/node.go:697:14: d.preparePublishTarget undefined (type *nodeService has no field or method preparePublishTarget)
pkg/driver/node.go:697:14: too many errors

Anything else we need to know?:

I don't actually want to run the driver on MacOS, but I do want to run e2e tests to validate my installation of the driver.
Currently I can work around this by running the tests in a container.

Environment

  • Kubernetes version (use kubectl version): EKS 1.22
  • Driver version: v1.17.0
@k8s-ci-robot k8s-ci-robot added the kind/bug Categorizes issue or PR as related to a bug. label Apr 3, 2023
@wmedlar
Copy link
Author

wmedlar commented Apr 3, 2023

#796 is related, but was closed without any changes being made.

@ConnorJC3
Copy link
Contributor

Hi, building for Darwin is intentionally not supported, as the EBS CSI Driver cannot run on Darwin. Building for Darwin should not be required to run the e2e tests (you will need to build for Linux, as the e2e tests must be run on a real cluster on AWS).

@wmedlar
Copy link
Author

wmedlar commented Apr 11, 2023

The e2e tests import code from the driver, which is why building on darwin is required. The driver itself and the resources created by the tests are all run in a real cluster. Like I mentioned in the original post, I don't have any interest in running the driver on darwin. I should, however, be able to run the e2e tests from my laptop without having to jump through hoops.

A stub implementation of the nodeService would be plenty fine, as would a clean separation between the application code and the e2e tests.

@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough contributors to adequately respond to all issues.

This bot triages un-triaged issues according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Mark this issue as fresh with /remove-lifecycle stale
  • Close this issue with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle stale

@k8s-ci-robot k8s-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Jan 21, 2024
@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues.

This bot triages un-triaged issues according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Mark this issue as fresh with /remove-lifecycle rotten
  • Close this issue with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle rotten

@k8s-ci-robot k8s-ci-robot added lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. and removed lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. labels Feb 20, 2024
@AndrewSirenko
Copy link
Contributor

/remove-lifecycle rotten

@k8s-ci-robot k8s-ci-robot removed the lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. label Feb 22, 2024
@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough contributors to adequately respond to all issues.

This bot triages un-triaged issues according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Mark this issue as fresh with /remove-lifecycle stale
  • Close this issue with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle stale

@k8s-ci-robot k8s-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label May 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Categorizes issue or PR as related to a bug. lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale.
Projects
None yet
Development

No branches or pull requests

6 participants