On boarding of a new CF system build pack for Rust
Borrmann, Andre <a.borrmann@...>
Hi there CF community,
While Rust is still kind of a young but continuously growing language it has been voted to be one of the most beloved development languages several years in a row. I’m wondering if there are any plans to provide a Rust “system buildpack” natively integrated into Cloud Foundry. If there are no such plans yet, I’d like to understand what the key drivers would be to achieve such a thing. What are the prerequisites and what are possible contributions to drive or support the efforts around this topic.
Thanks in advance for any pointers to achieve the goal of having a system buildpack for Rust available on Cloud Foundry.
Besst Regards,
André Borrmann Development Expert Strategic Projects | New Ventures and Technologies | Technology & Innovation SAP SE, Konrad-Zuse-Ring 10, 14469 Potsdam, Germany
Pflichtangaben/Mandatory Disclosure Statements:
|
|
Daniel Mikusa <dmikusa@...>
Hi,
toggle quoted message
Show quoted text
Not sure this exactly answers your question. I am also Rust fan and so a while back felt compelled to write a set of Cloud Native buildpacks (v3 buildpack) for Rust & contributed it to the Paketo community (Paketo is a CF Foundation project for
implementations of the v3 cloud native buildpack spec).
I haven't tried it, but I'm pretty sure you could `pack build` images with this buildpack and `cf push -o` them onto CF. It's one extra step, but it should work.
Maybe there'd be a way to retrofit it to work as a v2 CF buildpack? I think some folks were working on a wrapper a while back.
Dan
|
|
Dr Nic Williams <drnicwilliams@...>
Skipping the question of “core buildpacks” which is a good one but I can’t answer it.
I can point you to two paths for authoring Buildpacks, depending on which CF your using. Newer CF/kubernetes CF uses Paketo buildpacks https://paketo.io/ which are implementations of the Cloud Native Buildpacks project https://buildpacks.io — the latter page has a tutorial for creating a buildpack; and the former is a collection of buildpacks. If you want your Rust buildpack to be “core” one day, cargo cult the core team/paketo team’s buildpacks rather than implement yours from scratch. If you’re on an older CF, and using the older buildpacks then yes you can create a Rust buildpack, but it will never be included in “core” — the core team/paketo team is solely working on the new set of buildpakcs above. I wrote some tutorials for creating the older buildpacks; but I hesitate to recommend them since they are “the old way” :) Dr Nic -- Dr Nic Williams +61 437 276 076 twitter @drnic |
|
Adding this to the conversation:
I found it trivial to modify emk/heroku-buildpack-rust into alphagov/cf-buildpack-rust to work with our UK government CF deployment here at the GDS. Others will have done it better, I am sure, but it was so easy to get it going. Tris Oaten Senior Dev, GDS |
|
Borrmann, Andre
Hi Dan,
thanks for your reply. While a custom/community buildpack is a viable option my question is more related to an enterprise context. Which means, building enterprise applications and deploy them to CF. This would require reproducible build steps and thus should not be dependent on external hosted buildpacks. So either we would require the custom buildpack to be hosted within our enterprise boundaries or – the preferred option – being part of the CF stack itself, like JAVA buildpack, GO buildpack etc. (so it should be best listed here: https://docs.cloudfoundry.org/buildpacks/system-buildpacks.html).
This kind of lead to the question how those buildpaks became system build packs and how could Rust become a part of this party. Where should this being requested and who would be responsible to get this “onboarding” kicked off.
Thanks in advance.
BR André
From: <cf-dev@...> on behalf of Daniel Mikusa <dmikusa@...>
Hi,
Not sure this exactly answers your question. I am also Rust fan and so a while back felt compelled to write a set of Cloud Native buildpacks (v3 buildpack) for Rust & contributed it to the Paketo community (Paketo is a CF Foundation project for implementations of the v3 cloud native buildpack spec).
I haven't tried it, but I'm pretty sure you could `pack build` images with this buildpack and `cf push -o` them onto CF. It's one extra step, but it should work.
Maybe there'd be a way to retrofit it to work as a v2 CF buildpack? I think some folks were working on a wrapper a while back.
Dan
|
|
Borrmann, Andre
Hi Dr. Nic,
thanks for your reply and the links shared to the new buildpacks and the tutorial. As I’d like to use the buildpack within an enterprise context such custom buildpack would be a good starting point, but the ultimate goal would be to get it listed as part of this: https://docs.cloudfoundry.org/buildpacks/system-buildpacks.html
If I get you right, the CF core team/paketo team might be the right contacts to talk to about this topic to get a Rust buildpack eventually a core/system buildpack? Are you able to share some contact details to start the communication with the right audience straight away?
Thanks in advance.
BR André
From: <cf-dev@...> on behalf of Dr Nic Williams <drnicwilliams@...>
Skipping the question of “core buildpacks” which is a good one but I can’t answer it.
I can point you to two paths for authoring Buildpacks, depending on which CF your using.
Newer CF/kubernetes CF uses Paketo buildpacks https://paketo.io/ which are implementations of the Cloud Native Buildpacks project https://buildpacks.io — the latter page has a tutorial for creating a buildpack; and the former is a collection of buildpacks. If you want your Rust buildpack to be “core” one day, cargo cult the core team/paketo team’s buildpacks rather than implement yours from scratch.
If you’re on an older CF, and using the older buildpacks then yes you can create a Rust buildpack, but it will never be included in “core” — the core team/paketo team is solely working on the new set of buildpakcs above. I wrote some tutorials for creating the older buildpacks; but I hesitate to recommend them since they are “the old way” :)
Dr Nic -- Dr Nic Williams +61 437 276 076 twitter @drnic |
|
Dr Nic Williams <drnicwilliams@...>
Custom buildpacks (v2) can be installed in airgapped and enterprise CF. You convert the buildpack and it’s dependencies into a zip file and the CF admin installs it for all users to share, like you would upgrade a buildpack from the core CF team. Paketo buildpacks (v3) — your own plus upstream — are baked into your builder Docker image, so again you have control over what buildpack you are using across all apps. Nic On Mon, 10 May 2021 at 6:28 pm, Borrmann, Andre via lists.cloudfoundry.org <a.borrmann=sap.com@...> wrote:
--
Dr Nic Williams +61 437 276 076 twitter @drnic |
|
Kashyap Vedurmudi
Hi all - My team at VMware contributes to both the v2 Cloud Foundry buildpacks as well as the Paketo Buildpacks project (v3). Just to re-iterate a couple points above and add a few others, you have a couple options here:
As others in the thread have mentioned, my team at VMware is focusing most of our development efforts on v3 Paketo Buildpacks and likely won't have the bandwidth to build a v2 Rust buildpack. That said, Rust is definitely growing in popularity, so I'm
happy to discuss any of these options above in depth, André. Feel free to keep the discussion going here or start a thread in the #buildpacks channel on CF slack.
Thanks,
Kashyap
From: cf-dev@... <cf-dev@...> on behalf of Dr Nic Williams <drnicwilliams@...>
Sent: Monday, May 10, 2021 4:45 AM To: cf-dev@... <cf-dev@...> Subject: Re: [cf-dev] On boarding of a new CF system build pack for Rust Custom buildpacks (v2) can be installed in airgapped and enterprise CF. You convert the buildpack and it’s dependencies into a zip file and the CF admin installs it for all users to share, like you would upgrade a buildpack from the core CF
team.
Paketo buildpacks (v3) — your own plus upstream — are baked into your builder Docker image, so again you have control over what buildpack you are using across all apps.
Nic
On Mon, 10 May 2021 at 6:28 pm, Borrmann, Andre via
lists.cloudfoundry.org <a.borrmann=sap.com@...> wrote:
Dr Nic Williams
+61 437 276 076
twitter @drnic
|
|
Daniel Mikusa <dmikusa@...>
+1 to everything Dr Nic said.
toggle quoted message
Show quoted text
|
|