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

Entrypoint: Produce static binary for entry #1850

Closed
wants to merge 1 commit into from
Closed

Entrypoint: Produce static binary for entry #1850

wants to merge 1 commit into from

Conversation

darkmuggle
Copy link
Contributor

This allows for entrypoint to be portable and cleans-up some cruft.

This allows for entrypoint to be portable.
@openshift-ci-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: darkmuggle

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@darkmuggle
Copy link
Contributor Author

Follow-on PR to @mike-nguyen 's comment in #1824 about .PHYON.

@cgwalters
Copy link
Member

I don't understand why it needs to be portable?

@darkmuggle
Copy link
Contributor Author

I don't understand why it needs to be portable?

Testing. The next PR coming allows for Entry to become a CI runner from a COSA container. If you compile entry on F33, it will not work on F32 due to a libc difference. Portable makes it much easier for testing.

@cgwalters
Copy link
Member

cgwalters commented Nov 11, 2020

If you compile entry on F33, it will not work on F32 due to a libc difference.

Right but that implies we're "breaking" containerization.

Portable makes it much easier for testing.

Is this something like doing a make from your workstation and then copying the binary into a running container? Any reason why not instead to do a podman build - that's the standard container flow, and the more we make our workflow like that, the more it resembles how people build containerized applications too.

We already have a Dockerfile.dev that just layers on top of the existing cosa.

We ran into a really horrible bug in the OpenShift cluster network operator which was copying a fully statically linked binary from a container out to the host - trying to use FIPS completely broke it because it dynamically links openssl. Upstream glibc nearly doesn't support static linking. It will break things like the systemd nss plugin, etc. This led to coreos/fedora-coreos-tracker#354

Ultimately I would say this is still your call - I'm not trying to block this PR but I also think it's really important that we have a shared understanding of architecture/tooling - things like copying binaries versus containers is one of those.

@darkmuggle
Copy link
Contributor Author

Is this something like doing a make from your workstation and then copying the binary into a running container? Any reason why not instead to do a podman build - that's the standard container flow, and the more we make our workflow like that, the more it resembles how people build containerized applications too.

Yes, this is pure developer-driven PR to reduce friction. COSA is huge, and right now, entrypoint uses in-cluster credentials for creating pods. By having a static build, it's a faster build. Although I suppose I could just make in a COSA container.

Ultimately I would say this is still your call - I'm not trying to block this PR but I also think it's really important that we have a shared understanding of architecture/tooling - things like copying binaries versus containers is one of those.

Agreed. And TBH, I would really bristle if were distributing a straight-up binary and doing a binary copy game. I think I would like to land this for the developer story. The production and consumer stories should remain container-based.

Once entry stabilizes, this can be something that's revisited.

@darkmuggle
Copy link
Contributor Author

darkmuggle commented Nov 11, 2020

Actually, I'm rolling with @cgwalters objection -- it sounds, reasonable, and codifying my developer pain-point (identified above) in the code is a bit short-sighted.

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

Successfully merging this pull request may close these issues.

3 participants