Skip to content

Add development Dockerfile with all dependencies and CI workflow for mollerdb - #28

Merged
wdconinc merged 13 commits into
mainfrom
copilot/add-dockerfile-for-mollerdb
Nov 2, 2025
Merged

wdconinc merged 13 commits into
mainfrom
copilot/add-dockerfile-for-mollerdb

Conversation

Copilot AI commented Nov 1, 2025 •

Copy link
Copy Markdown
Contributor

Adds a complete Docker development environment with all C++ and Python build dependencies, matching the CI configuration, along with automated building and publishing via GitHub Actions.

Implementation

Dockerfile (Ubuntu 24.04):

  • GCC 14 from universe repository for C++23 support (sqlpp23 requirement)
  • CMake 3.28+, build-essential
  • Node.js 18 + dbml-cli for schema generation
  • PostgreSQL client libraries (libpq-dev)
  • Apache Arrow C++ libraries with network fallback
  • Python 3.12 + scikit-build-core, pybind11, pyparsing, pytest, wheel, build
  • Non-root developer user (UID 1001)

GitHub Actions Workflow (.github/workflows/docker.yml):

  • Builds Docker image on every push, PR, and manual trigger
  • Verifies build completes by running pip install -e . in container
  • Publishes to GitHub Container Registry (ghcr.io/jeffersonlab/mollerdb) on pushes to main
  • Publishes versioned tags on releases (e.g., v1.0.0 → 1.0.0, 1.0, 1, latest)
  • Uses Docker layer caching for faster builds

Documentation:

  • README.md: Quick start with pre-built images from GHCR and local build instructions
  • docs/README.md: Detailed workflows, manual Arrow installation, security notes

Usage

Using pre-built image:

docker pull ghcr.io/jeffersonlab/mollerdb:latest
docker run -it --rm -v $(pwd):/workspace ghcr.io/jeffersonlab/mollerdb:latest

Building locally:

docker build -t mollerdb-dev .
docker run -it --rm -v $(pwd):/workspace mollerdb-dev

# Inside container
git submodule update --init --recursive
pip install -e . --verbose --break-system-packages

Notes

  • SSL verification disabled for npm/pip to handle certificate issues in build environments—remove for production
  • Apache Arrow requires network access to packages.apache.org during build; fallback documented if unavailable
  • PEP 668 requires --break-system-packages flag (safe in containers)
  • Pre-built images automatically published to GHCR on main pushes and releases

Delivers Phase 0 infrastructure from #19.

[!WARNING]

Original prompt

This section details on the original issue you should resolve

<filter_complete></filter_complete>

<issue_title>Add development Dockerfile with all dependencies for mollerdb</issue_title>
<issue_description>Deliverable: A complete Dockerfile that builds a development environment for mollerdb, including all dependencies required for both C++ and Python development. This includes libraries such as libpq, Apache Arrow, pybind11, scikit-build-core, and all tools needed to build and test both native and Python wheels. The Dockerfile should:

  • Start from an appropriate base image (e.g., ubuntu:22.04 or similar)
  • Install build-essential, CMake, Python (with pip), PostgreSQL client libraries, libpq, Arrow, pybind11, and any dependencies needed for scikit-build-core
  • Install Python development tools: pytest, wheel, build, scikit-build-core
  • Add a non-root user for development
  • Provide instructions/comments on how to use the Dockerfile for local builds and testing

Definition of Done:

  • Dockerfile builds successfully on docker build
  • All dependencies are present for both C++ and Python development
  • README or docs/README.md updated with instructions for using Docker
  • Image can execute C++ and Python tests as run in CI
  • Example command to start a dev shell and run tests is provided in the documentation

Context:

Comments on the Issue (you are @copilot in this section)

Original prompt

This section details on the original issue you should resolve

<issue_title>Add development Dockerfile with all dependencies for mollerdb</issue_title>
<issue_description>Deliverable: A complete Dockerfile that builds a development environment for mollerdb, including all dependencies required for both C++ and Python development. This includes libraries such as libpq, Apache Arrow, pybind11, scikit-build-core, and all tools needed to build and test both native and Python wheels. The Dockerfile should:

  • Start from an appropriate base image (e.g., ubuntu:22.04 or similar)
  • Install build-essential, CMake, Python (with pip), PostgreSQL client libraries, libpq, Arrow, pybind11, and any dependencies needed for scikit-build-core
  • Install Python development tools: pytest, wheel, build, scikit-build-core
  • Add a non-root user for development
  • Provide instructions/comments on how to use the Dockerfile for local builds and testing

Definition of Done:

  • Dockerfile builds successfully on docker build
  • All dependencies are present for both C++ and Python development
  • README or docs/README.md updated with instructions for using Docker
  • Image can execute C++ and Python tests as run in CI
  • Example command to start a dev shell and run tests is provided in the documentation

Context:

Comments on the Issue (you are @copilot in this section)


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Copilot AI and others added 3 commits November 1, 2025 21:50
Co-authored-by: wdconinc <4656391+wdconinc@users.noreply.github.com>
Co-authored-by: wdconinc <4656391+wdconinc@users.noreply.github.com>
Co-authored-by: wdconinc <4656391+wdconinc@users.noreply.github.com>
@wdconinc

wdconinc commented Nov 1, 2025

Copy link
Copy Markdown
Member

@copilot Add a GitHub Actions workflow that builds this container, and use it to verify that the build in this container completes correctly. On pushes to main, and on releases, publish this container to the GitHub Container Registry.

Co-authored-by: wdconinc <4656391+wdconinc@users.noreply.github.com>
Copilot AI changed the title [WIP] Add development Dockerfile for mollerdb with all dependencies Add development Dockerfile with all dependencies for mollerdb Nov 1, 2025
Copilot AI requested a review from wdconinc November 1, 2025 22:02
@wdconinc
wdconinc marked this pull request as ready for review November 1, 2025 22:02
Copilot AI review requested due to automatic review settings November 1, 2025 22:02

Copilot AI 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.

Pull Request Overview

This PR adds comprehensive Docker development environment support to the mollerdb project, making it easier for developers to get started without manually installing dependencies. The changes introduce a new Dockerfile with all required dependencies and update documentation to guide users through Docker-based and native development workflows.

  • Adds a production-ready Dockerfile with Ubuntu 24.04, GCC 14, and all required dependencies
  • Updates README.md with Docker development instructions alongside native installation
  • Updates docs/README.md with detailed Docker usage and troubleshooting guidance

Reviewed Changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 5 comments.

File Description
Dockerfile New Docker development environment with Ubuntu 24.04, GCC 14, Python 3.12, and all build dependencies
README.md Added Docker development section with build and usage instructions
docs/README.md Added comprehensive Docker quick start guide as the recommended approach, with troubleshooting notes

Comment thread docs/README.md Outdated
Comment thread Dockerfile Outdated
Comment thread Dockerfile Outdated
Comment thread docs/README.md Outdated
Comment thread Dockerfile
Co-authored-by: wdconinc <4656391+wdconinc@users.noreply.github.com>

Copilot AI commented Nov 1, 2025

Copy link
Copy Markdown
Contributor Author

@copilot Add a GitHub Actions workflow that builds this container, and use it to verify that the build in this container completes correctly. On pushes to main, and on releases, publish this container...

Added in commit e162a1e. The workflow:

  • Builds the Docker image on every push, PR, and workflow dispatch
  • Verifies the build completes by running pip install -e . inside the container
  • Publishes to ghcr.io/jeffersonlab/mollerdb on pushes to main and on version tags
  • Uses semver tags (e.g., v1.0.0 → 1.0.0, 1.0, 1, latest)
  • Includes Docker layer caching for faster builds

Documentation updated to reference the pre-built images from GitHub Container Registry.

Copilot AI changed the title Add development Dockerfile with all dependencies for mollerdb Add development Dockerfile with all dependencies and CI workflow for mollerdb Nov 1, 2025
wdconinc and others added 6 commits November 1, 2025 17:35
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Added error handling for Arrow APT source download.
Comment thread .github/workflows/docker.yml Outdated
@wdconinc
wdconinc merged commit c9968aa into main Nov 2, 2025
11 checks passed
@wdconinc
wdconinc deleted the copilot/add-dockerfile-for-mollerdb branch November 2, 2025 00:18
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.

Add development Dockerfile with all dependencies for mollerdb

3 participants