Skip to content

Support meltano container build [LFXV2-870]#20

Merged
emsearcy merged 10 commits intomainfrom
ems/meltano-containers
Dec 19, 2025
Merged

Support meltano container build [LFXV2-870]#20
emsearcy merged 10 commits intomainfrom
ems/meltano-containers

Conversation

@emsearcy
Copy link
Contributor

Summary

This PR enhances the Docker configuration by introducing a dedicated meltano container and improving the overall build system organization.

Changes

Docker Infrastructure

  • New meltano container: Added docker/Dockerfile.meltano with optimized multi-stage build
  • 🔧 Separate build targets: Split Docker operations into distinct v1-sync-helper and meltano targets
  • 📦 Improved .dockerignore: Enhanced with comprehensive glob patterns for better exclusions

Build System Improvements

  • 🎯 Makefile enhancements: Added separate targets for each container type
    • docker-build-v1-sync-helper / docker-run-v1-sync-helper
    • docker-build-meltano / docker-run-meltano
    • docker-build-all for building both containers
  • 📚 Enhanced help documentation: Updated help target with detailed descriptions for new commands

Configuration Updates

  • 🛠️ meltano.yml formatting: Minor YAML formatting improvements for consistency

Technical Details

The new meltano container:

  • Uses multi-stage build for optimized image size
  • Runs as non-root user for security
  • Includes proper environment variable configuration
  • Supports various sync scenarios (PostgreSQL, DynamoDB, etc.)

Testing

  • Build v1-sync-helper container: make docker-build-v1-sync-helper
  • Build meltano container: make docker-build-meltano
  • Build all containers: make docker-build-all
  • Verify container functionality

Notes

This is part of the effort to improve containerization and deployment flexibility for the LFX v1 sync helper system.


🤖 Assisted with GitHub Copilot (via Zed)

…oved build targets

- Update .dockerignore with comprehensive glob patterns for better exclusions
- Add separate Docker targets for v1-sync-helper and meltano containers
- Create dedicated Dockerfile.meltano with optimized multi-stage build
- Improve Makefile with distinct build and run targets for each service
- Add help documentation for new Docker targets
- Minor YAML formatting fixes in meltano.yml

🤖 Assisted with [GitHub Copilot](https://github.com/features/copilot) (via Zed)

Signed-off-by: Eric Searcy <eric@linuxfoundation.org>
@emsearcy emsearcy changed the title Enhance Docker configuration with separate meltano container and improved build targets Support meltano container build [LFXV2-870] Dec 12, 2025
- Create comprehensive development-focused documentation for AI agents
- Document repository structure, build system, and container targets
- Include new Makefile targets for container builds (v1-sync-helper, meltano)
- Focus on codebase modification workflows rather than deployment procedures
- Cover Go service architecture, Python ETL patterns, and CI/CD integration

🤖 Generated with [GitHub Copilot](https://github.com/features/copilot) (via Zed)

Signed-off-by: Eric Searcy <eric@linuxfoundation.org>
- Rename ko-build-main.yaml to publish-main.yaml
- Rename ko-build-tag.yaml to publish-release.yaml
- Add new Meltano Docker build and release pipeline to publish-release.yaml
- Implement sequential job dependencies: v1-sync-helper → meltano → helm-chart
- Update AGENTS.md documentation to reflect new workflow structure
- Maintain complete SLSA provenance and Cosign signing for all artifacts

🤖 Generated with [GitHub Copilot](https://github.com/features/copilot) (via Zed)

Signed-off-by: Eric Searcy <eric@linuxfoundation.org>
Signed-off-by: Eric Searcy <eric@linuxfoundation.org>
Signed-off-by: Eric Searcy <eric@linuxfoundation.org>
Signed-off-by: Eric Searcy <eric@linuxfoundation.org>
@emsearcy emsearcy marked this pull request as ready for review December 18, 2025 20:43
@emsearcy emsearcy requested a review from a team as a code owner December 18, 2025 20:43
Copilot AI review requested due to automatic review settings December 18, 2025 20:43
Copy link
Contributor

Copilot AI left a comment

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 enhances the Docker containerization infrastructure by introducing a dedicated Meltano container with optimized multi-stage builds, reorganizes the build system with separate targets for each container type, and updates dependencies and configurations for improved consistency.

Key changes:

  • Introduced new docker/Dockerfile.meltano with multi-stage build using uv for Python dependency management
  • Enhanced Makefile with separate build/run targets for v1-sync-helper and meltano containers
  • Updated CI/CD workflows to build and publish both containers with proper dependency ordering and SLSA provenance

Reviewed changes

Copilot reviewed 16 out of 18 changed files in this pull request and generated no comments.

Show a summary per file
File Description
docker/Dockerfile.meltano New multi-stage Dockerfile for Meltano container with uv-based builds and non-root security
meltano/Dockerfile Removed legacy Dockerfile in favor of centralized docker/ directory
Makefile Added separate build targets for v1-sync-helper and meltano containers with comprehensive help documentation
.dockerignore Enhanced with comprehensive glob patterns for better build context exclusion
pyproject.toml Version bump to 0.1.1 and meltano dependency updated to 4.0.6 with s3 extras
uv.lock Dependency updates including boto3/botocore additions for S3 support
meltano/meltano.yml YAML formatting improvements for consistency (quotes, spacing)
.github/workflows/publish-release.yaml Split into separate jobs for v1-sync-helper and meltano with provenance generation
.github/workflows/publish-main.yaml Job renamed for clarity (publish-v1-sync-helper)
.github/workflows/mega-linter.yml Updated MegaLinter version from 8.7.0 to 9.1.0
AGENTS.md New comprehensive documentation for AI agents/developers
research/*.md Markdown table formatting improvements for consistency
cmd/lfx-v1-sync-helper/README.md Table formatting improvements
charts/lfx-v1-sync-helper/README.md Table formatting improvements
.secretlintignore Added meltano plugin lock files to ignore list
.lycheeignore Extended regex to include nats:// protocol

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@emsearcy emsearcy requested a review from jordane December 18, 2025 20:47
Add shell script that generates a single Kubernetes ConfigMap containing
catalogs from specified Meltano taps. Features:

- Single ConfigMap with multiple keys (tap-name-catalog.json format)
- Uses standard MELTANO_* environment variables
- Displays current AWS account/profile and Meltano environment info
- Captures meltano stderr to temp files for better error debugging
- Validates JSON output and compacts for storage efficiency
- Can output to file or stdout

🤖 Generated with GitHub Copilot (https://github.com/features/copilot) (via Zed)

Signed-off-by: Eric Searcy <eric@linuxfoundation.org>
Split catalog generation back to individual ConfigMaps per tap instead
of a single large ConfigMap to avoid Kubernetes size limits (1MB max).
Also fix YAML document separator formatting issues.

Changes:
- Generate separate ConfigMaps (tap-dynamodb-catalog, tap-postgres-catalog)
- Restore lfx.linuxfoundation.org/tap label for each ConfigMap
- Fix YAML document separator (---) placement and indentation
- Avoid ConfigMap size limit errors

🤖 Generated with GitHub Copilot (https://github.com/features/copilot) (via Zed)

Signed-off-by: Eric Searcy <eric@linuxfoundation.org>
Add jq filtering to only include streams with selected=true in the
generated catalog ConfigMaps. This dramatically reduces size by
excluding ~4,969 unselected streams and keeping only ~616 selected
streams, preventing Kubernetes ConfigMap size limit issues.

🤖 Generated with GitHub Copilot (https://github.com/features/copilot) (via Zed)

Signed-off-by: Eric Searcy <eric@linuxfoundation.org>

# Run meltano Docker container
docker-run-meltano: docker-build-meltano
@echo "Summoning a dragon with the meltano Docker container..."

Choose a reason for hiding this comment

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

wat?

Choose a reason for hiding this comment

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

Oooh..Meltano's logo is a dragon. Got it.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It prints one of several ascii-art dragons ... actually the GenAI output for this was to have it run "--help", but I changed it to be a little more fun. It's not reasonable to actually do anything with that container from a makefile, given it needs lots of different command line arguments to do different things ... but it does help work as a test that the app can "bootstrap".

Copy link
Contributor Author

@emsearcy emsearcy Dec 19, 2025

Choose a reason for hiding this comment

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

% uv run meltano --help | grep dragon
  dragon       Summon a dragon!
% uv run meltano dragon


                                                 /===-_---~~~~~~~~~------____
                                                |===-~___                _,-'
                 -==\\                         `//~\\   ~~~~`---.___.-~~
             ______-==|                         | |  \\           _-~`
       __--~~~  ,-/-==\\                        | |   `\        ,'
    _-~       /'    |  \\                      / /      \      /
  .'        /       |   \\                   /' /        \   /'
 /  ____  /         |    \`\.__/-~~ ~ \ _ _/'  /          \/'
/-'~    ~~~~~---__  |     ~-/~         ( )   /'        _--~`
                  \_|      /        _)   ;  ),   __--~~
                    '~~--_/      _-~/-  / \   '-~ \\
                   {\__--_/}    / \\_>- )<__\      \\
                   /'   (_/  _-~  | |__>--<__|      |
                  |0  0 _/) )-~     | |__>--<__|      |
                  / /~ ,_/       / /__>---<__/      |
                 o o _//        /-~_>---<__-~      /
                 (^(~          /~_>---<__-      _-~
                ,/|           /__>--<__/     _-~
             ,//('(          |__>--<__|     /                  .----_
            ( ( '))          |__>--<__|    |                 /' _---_~\\
         `-)) )) (           |__>--<__|    |               /'  /     ~\`\\
        ,/,'//( (             \__>--<__\    \            /'  //        ||
      ,( ( ((, ))              ~-__>--<_~-_  ~--____---~' _/'/        /'
    `~/  )` ) ,/|                 ~-_~>--<_/-__       __-~ _/
  ._-~//( )/ )) `                    ~~-'_/_/ /~~~~~~~__--~
   ;'( ')/ ,)(                              ~~~~~~~~~~
  ' ') '( (/
    '   '  `

@emsearcy emsearcy merged commit 79b0146 into main Dec 19, 2025
3 checks passed
@emsearcy emsearcy deleted the ems/meltano-containers branch December 19, 2025 00:05
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.

4 participants