-
Notifications
You must be signed in to change notification settings - Fork 113
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
Build images using the binary of my application #97
Comments
@zhangtbj thoughts? |
Hi @sbose78 , When you talking about the Do you have this requirement before? I didn't see this type on the OpenShift console before. I remember the Tekton can use it as a kind of resource, but I can not 100% make sure about that. If Tekton doesn't support that, we should extract by ourselves at the beginning of the build. At least, right now, we don't have this requirement. We can support that, but it is not on our 2Q delivery list now :) |
I remember wrong. The kaniko support to use tar file: |
By Binary I mean, that the application code is already built into a jar/war in case of Java. All that remains is that it needs to be put into a deployable image. |
Does that binary require any runtime support which inside of the deployable image? I don't know if there is any build tool to support it for normal Dockerfile or CF(buildpacks) application. But we tried the similar work before for I think jar/war is a special case just for Java. other language apps should base on tar file. Is there any background/requirement detail behind that? Or do you know what tool can support it? |
|
Is there a unify solution/binary to solve these three different languages as a whole? Can RedHat s2i binary do that? Or other tool? |
Not really, the intention is to support a spec.output.base section where a user should be able to specify
There would be runtime image specific optional buildSteps which would effectively execute a equivalent of a multi-stage build. |
Of course all of this is optional. |
For now, Dockerfile and buildpacks are high priority for us. I think if we have this kind of requirement. We can plan it after 2Q :) |
No worries, @otaviof is working on this, we'll discuss on a PR soon when it's up :) |
👍 :) |
For me, it's not so much important whether its an already compiled binary or the source code that it is compiled, it's about how the code (binary or source) is obtained. Typically in a CI/CD context you refer to the source via a Git or other SCM URL, which then is downloaded from there. In contrast, in S2I a binary input (regardless of whether its an S2I, Docker or custom strategy) is uploaded from the local disc. Typically this is source (s2i/buildpack), or its a docker.tar container a Docker build context (e.g. for buildah/kaniko), but the important bit is that it's uploaded via an HTTP post. For S2I the upload happens over a customer API endpoint So I think you should rephrase your initial comment: It's really not about the binary aspect (i.e. some executable) but about a local upload (called "binary input" in S2I lingo) |
Ah, here's a POC with Buildah and Upload via an init-container: https://github.com/rhuss/buildah-poc |
The nice thing about using an init-container for the upload is that you have a nice synchronization point: The application container for the build will only start when the upload is finished (i.e. the init-container has been stopped). Of course, with Tekton you have probably many more possibilities to sync, this POC is just a poor men sync :) |
Hi @rhuss , And I am glad that we are discussing a real requirement. (I tagged it as Actually, I summarized almost ALL communities local upload/build support, and list in the doc, please also review, all:
So I prefer the rsync way or an upload service to help us to upload the image for build container/pod. I also investigated and summarized the oc binary build in another doc: I think it is a good way, and I think we can use the similar upload service/controller in this build repo to support the local file upload and pass it to the existing buildstrategy/build. Also cc @sbose78 |
Could we fork this into a separate issue so that this receives proper attention? :)
|
aha, yes, agree. It mixes the Let us discuss the local(binary) build in other issue: |
Meant to follow up on this - I propose the following terminology so we don't confuse this capability from OCP
As @zhangtbj and @sbose78 suggested, we should treat these separately. |
Closing this issue, local source code support will be prototyped while developing https://github.com/shipwright-io/cli and we can use #59 for discussion. Remote artifacts already have a proposal in https://github.com/shipwright-io/build/blob/master/docs/proposals/remote-artifacts.md . |
Enable build source images which fixes EC violation Signed-off-by: Satyam Bhardwaj <sabhardw@redhat.com> rh-pre-commit.version: 2.3.0 rh-pre-commit.check-secrets: ENABLED
As a developer, I want to build images using the binary of my application (e.g. app.jar) so that I can make use of artifacts produced in our existing CI process and stored on repositories like Nexus when building images.
Problem:
Users have existing CI processes that often builds the binary of the application and store it in a repository. It's generally recommended to reuse the same app binary in the delivery phases after CI rather than rebuilding it during the image build phase. These binaries might be signed which prevent the customer from using build strategies that rebuild the binary of the application again.
Why is this important?
To allow users to use Builds as the extension of their CI and reuse existing app binaries for building images via Builds.
The text was updated successfully, but these errors were encountered: