Sponsored Content
Skip to content

feat: Implement nix-based Dockerfile for CI - #7083

Merged
bthomee merged 23 commits into
XRPLF:developfrom
mathbunnyru:nix_docker
May 13, 2026
Merged

feat: Implement nix-based Dockerfile for CI#7083
bthomee merged 23 commits into
XRPLF:developfrom
mathbunnyru:nix_docker

Conversation

@mathbunnyru

@mathbunnyru mathbunnyru commented May 6, 2026

Copy link
Copy Markdown
Contributor

High Level Overview of Change

I implement nixos-packages build Docker images.

This allows us to have the following:

  • Modern compilers (gcc / clang)
  • unified declaration of tools/packages required for development/building/testing of rippled
  • No Docker Images duplication depending on the OS and/or versions
  • And the Dockerfile will be stored here, since it'll be less frequently updated and easier to support

All that being said, we use libc of the oldest distro we support.
ubuntu:20.04 had libc 2.31, so we have to:

  • build this libc version
  • build gcc with this libc
  • and libstdc++ as well

This allows us to build binaries compatible with old OS, but have all the features of the modern compilers.

Current limitations (not going to be addressed in this PR, but will be resolved in the future):

  • only linux/amd64
  • only gcc-15 (clang will be added later)
  • not yet tested if rippled is capable of being built in this image, but tools are verified to be working (i.e. we run cmake --version in the image)

The base builder image ends up being the same (nixos), so it gets rebuilt every time.
But let's not worry about it too much - it won't be updated very often, so it shouldn't be too much of a problem.
And it's all in parallel, so we should be good too.

Context of Change

API Impact

  • Public API: New feature (new methods and/or new fields)
  • Public API: Breaking change (in general, breaking changes should only impact the next api_version)
  • libxrpl change (any change that may affect libxrpl or dependents of libxrpl)
  • Peer protocol change (must be backward compatible or bump the peer protocol version)

Copilot AI review requested due to automatic review settings May 6, 2026 16:04
@mathbunnyru
mathbunnyru requested review from bthomee and kuznetsss May 6, 2026 16:16
Comment thread nix/devshell.nix Outdated
Comment thread nix/ci-env.nix Outdated
Comment thread nix/ci-env.nix Outdated
Comment thread nix/ci-env.nix Outdated
@mathbunnyru
mathbunnyru force-pushed the nix_docker branch 4 times, most recently from 792fbc1 to b405ab8 Compare May 12, 2026 13:58
Comment thread nix/glibc231.nix Outdated
Comment thread nix/packages.nix Outdated
Comment thread nix/ci-env.nix Outdated
Comment thread nix/ci-env.nix Outdated
Comment thread flake.nix Outdated

@kuznetsss kuznetsss left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

👍

@mathbunnyru
mathbunnyru requested a review from godexsoft May 13, 2026 14:03
@mathbunnyru mathbunnyru added the Ready to merge *PR author* thinks it's ready to merge. Has passed code review. Perf sign-off may still be required. label May 13, 2026
@bthomee
bthomee added this pull request to the merge queue May 13, 2026
Merged via the queue into XRPLF:develop with commit 648ec74 May 13, 2026
1 check passed
@mvadari mvadari added this to the 3.2.0 milestone May 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Ready to merge *PR author* thinks it's ready to merge. Has passed code review. Perf sign-off may still be required.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants