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

Clean up Ruby patch release overrides #496

Merged
merged 1 commit into from
Jan 21, 2025

Conversation

stanhu
Copy link
Contributor

@stanhu stanhu commented Jan 20, 2025

RakeCompilerDock.cross_rubies supplies the exact patch release needed. This is available in rack-compiler-dock v1.9.1:

This simplifies the Dockerfile, but it does mean we have to keep the rake-compiler-dock version in the Gemfile in sync with all the images in docker/Dockerfile.*.

@@ -1,6 +1,7 @@
FROM ghcr.io/rake-compiler/rake-compiler-dock-image:1.8.0-mri-aarch64-linux
# Ensure this version matches the rack-compiler-version in Gemfile
FROM ghcr.io/rake-compiler/rake-compiler-dock-image:1.9.1-mri-aarch64-linux
Copy link
Contributor Author

@stanhu stanhu Jan 21, 2025

Choose a reason for hiding this comment

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

Should we template these files?

UPDATE: I see Dependabot is configured to update both the Gemfile and Dockerfiles separately. Perhaps we can just live with merging separate pull requests at the same time.

Copy link
Collaborator

Choose a reason for hiding this comment

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

One downside is that dependabot has a limit of PRs it will open, and it can be hard to know if all dockerfiles were updated properly.

Copy link
Contributor

Choose a reason for hiding this comment

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

If I understand your concern correctly: Dependabot now supports grouped updates so you can open one PR for multiple dependencies, rather than one per.

Gemfile Outdated
@@ -8,6 +8,7 @@ gemspec path: "examples/rust_reverse"
gem "rake", "~> 13.0"
gem "minitest", "5.15.0"
gem "rake-compiler", "~> 1.2.5" # Small bug in 1.2.4 that breaks Ruby 2.5
gem "rake-compiler-dock", "~> 1.9.1" # This should match the versions used in docker/Dockerfile.*
Copy link
Contributor

Choose a reason for hiding this comment

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

Nit, but shouldn't this be

Suggested change
gem "rake-compiler-dock", "~> 1.9.1" # This should match the versions used in docker/Dockerfile.*
gem "rake-compiler-dock", "1.9.1" # This should match the versions used in docker/Dockerfile.*

that way the version is absolutely pinned to the Dockerfile.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes, good point, thanks.

`RakeCompilerDock.cross_rubies` supplies the exact patch release
needed. This is available in rack-compiler-dock v1.9.1:

* rake-compiler/rake-compiler-dock#149
* https://github.com/rake-compiler/rake-compiler-dock/releases/tag/v1.9.1

This simplifies the `Dockerfile`, but it does mean we have to keep the
rake-compiler-dock version in the `Gemfile` in sync with all the
images in `docker/Dockerfile.*`.
@stanhu stanhu force-pushed the sh-simplify-ruby-patch-release branch from 969d7f9 to 99c1aee Compare January 21, 2025 19:02
@ianks
Copy link
Collaborator

ianks commented Jan 21, 2025

✅ Ty ty! We can fix the static build in a follow up

@ianks ianks merged commit 4c3508f into oxidize-rb:main Jan 21, 2025
55 of 56 checks passed
@stanhu
Copy link
Contributor Author

stanhu commented Jan 21, 2025

As I explained in #497, I believe the static build will be fixed by oxidize-rb/actions#52. I think we just need someone to release a new version?

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.

3 participants