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

Aads cargo chef to docker build for rust template #36

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

willemolding
Copy link

@willemolding willemolding commented Mar 19, 2024

When using sunodo for rust projects it is really slow to have to rebuild from scratch in docker every time.

Using cargo-chef this caches the build of the project dependencies and so only needs to rebuild the application itself. This makes running sunodo build significantly faster for any larger application.

This also bumps the rust version to 1.76.0 as cargo-chef doesn't support the older version

rust/Dockerfile Outdated Show resolved Hide resolved
@willemolding willemolding requested a review from tuler March 20, 2024 11:13
rust/Dockerfile Outdated
busybox-static=1:1.30.1-7ubuntu3 \
ca-certificates=20230311ubuntu0.22.04.1 \
curl=7.81.0-1ubuntu1.15
curl -fsSL https://github.com/cartesi/machine-emulator-tools/releases/download/v${MACHINE_EMULATOR_TOOLS_VERSION}/machine-emulator-tools-v${MACHINE_EMULATOR_TOOLS_VERSION}.tar.gz \
Copy link
Contributor

Choose a reason for hiding this comment

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

Please take a look at the other templates in the main branch.
We switched to use ADD instead of curl.
Just for consistency.

Copy link
Author

Choose a reason for hiding this comment

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

Nice that is much cleaner. Made the change here as well

@willemolding willemolding requested a review from tuler March 21, 2024 23:11
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.

2 participants