Repository to release images from Docker Hub and securely republish them within GitHub Packages in an auditable and reliable manner.
LibertyHub is designed to provide a transparent and secure way to import container images from external sources (initially Docker Hub) into GitHub Packages. This enhances security, provides audit trails, and reduces dependency on external registries.
- π Issue-Based Workflow: Users create an issue using a standardized template
- π€ Automated Processing: GitHub Workflows process the request with intelligent naming
- β Verification & Publishing: The system checks, imports and publishes with proper mapping
- π Audit Trail: All actions are logged for complete transparency
- ποΈ Source Selection: Choose the image source (initially Docker Hub, with plans to expand)
- π¦ Support for Official Images: Option to mark an image as an official Docker Hub image
- π Simple Request Process: Easy-to-use issue template with dropdown options
- π Latest Version Support: Option to select the latest version of an image
- π Automatic Updates: For images marked as "latest", duplicate requests will trigger an update
- π·οΈ Intelligent Naming: Smart naming convention with conflict resolution
- π Complete Audit Trail: All actions are logged, including image hashes, versions, and workflow details
- π« Duplicate Prevention: System verifies if the requested image already exists before processing
- οΏ½ Execution Control: Prevents duplicate workflow runs with smart event handling and state tracking
- οΏ½ποΈ Image Mapping: Advanced naming system to handle complex Docker Hub structures
Images are republished following the pattern:
- Official images:
ghcr.io/codaqui/dockerhub-<image>:<version> - Organization images:
ghcr.io/codaqui/dockerhub-<org>-<image>:<version>
The system uses intelligent extraction to handle various Docker Hub naming patterns:
Docker Hub: nginx:latest
GHCR: ghcr.io/codaqui/dockerhub-nginx:latest
Docker Hub: bitnami/nginx:latest
GHCR: ghcr.io/codaqui/dockerhub-bitnami-nginx:latest
Docker Hub: homeassistant/core:latest
GHCR: ghcr.io/codaqui/dockerhub-homeassistant-core:latest
Docker Hub: confluentinc/cp-kafka:latest
GHCR: ghcr.io/codaqui/dockerhub-confluentinc-cp-kafka:latest
Docker Hub: homeassistant/aarch64-homeassistant:latest
GHCR: ghcr.io/codaqui/dockerhub-homeassistant-aarch64-homeassistant:latest
Docker Hub: microsoft/mssql-server-linux:latest
GHCR: ghcr.io/codaqui/dockerhub-microsoft-mssql-server-linux:latest
Docker Hub: prom/prometheus:latest
GHCR: ghcr.io/codaqui/dockerhub-prom-prometheus:latest
Organization Names with Hyphens: β Not Supported
The system rejects organization names containing hyphens to avoid conflicts:
β REJECTED: docker-compose/nginx β Would create: dockerhub-docker-compose-nginx
β REJECTED: my-org/postgres β Would create: dockerhub-my-org-postgres
Why?: These create ambiguity in reverse mapping for automatic updates:
dockerhub-my-org-postgrescould be interpreted as:my-org/postgresβ (intended)my/org-postgresβ (wrong interpretation)
Workarounds:
- Use organizations without hyphens when possible
- Request official image status from Docker Hub
- Use alternative image sources (official variants)
Each import creates a mapping record:
{
"source_pattern": "homeassistant/core:latest",
"target_pattern": "dockerhub-homeassistant-core",
"mapping_type": "org_image_combination",
"original_repo": "homeassistant",
"original_image": "core",
"org_name": "homeassistant",
"image_name": "core",
"created": "2025-06-11T20:30:45Z"
}Mapping Types:
standard: Direct mapping (official images)org_image_combination: Organization + image name combinationsanitized_fallback: Fallback for complex structures
- Create Issue: Use the "Image Import Request" template
- Fill Information:
- Image source: Select "Docker Hub" from dropdown
- Official image: Check if it's an official Docker Hub image
- Repository name:
- β Leave empty for official images (nginx, ubuntu, postgres)
- β Required for organization images (bitnami, homeassistant, microsoft)
- Image name: The actual image name
- Version: Specific version or check "Use latest"
- Submit: The workflow processes automatically
- Track Progress: Updates provided in issue comments
- Use Image: Available in GitHub Packages with smart naming
β
Source: Docker Hub
β
Official: [x] This is an official Docker Hub image
β
Repository: [leave empty]
β
Image: nginx
β
Version: latest
Result: ghcr.io/codaqui/dockerhub-nginx:latest
β
Source: Docker Hub
β Official: [ ] This is an official Docker Hub image
β
Repository: homeassistant
β
Image: core
β
Version: latest
Result: ghcr.io/codaqui/dockerhub-homeassistant-core:latest
β
Source: Docker Hub
β Official: [ ] This is an official Docker Hub image
β
Repository: homeassistant
β
Image: aarch64-homeassistant
β
Version: latest
Result: ghcr.io/codaqui/dockerhub-homeassistant-aarch64-homeassistant:latest
β
Source: Docker Hub
β Official: [ ] This is an official Docker Hub image
β
Repository: microsoft
β
Image: mssql-server-linux
β
Version: 2019-latest
Result: ghcr.io/codaqui/dockerhub-microsoft-mssql-server-linux:2019-latest
To update an image tagged as "latest":
- Create a new import request with same details
- Check "Use latest" option
- System detects duplicate and updates automatically
- Audit trail shows before/after hashes
A scheduled workflow automatically updates all latest images daily:
- π Runs: Daily at midnight UTC
- π Manual trigger: Available via
workflow_dispatch - π Smart updates: Only updates when source image changed
- π Full audit: Complete logging and hash verification
Each import includes:
- π Source verification: Original Docker Hub image details
- π Hash tracking: SHA256 hashes before/after import
- π Timestamps: Complete temporal tracking
- π€ Attribution: User who requested import
- π Workflow logs: Full GitHub Actions execution logs
- ποΈ Mapping details: How naming was resolved
For updated images:
- π Previous state: Hash of existing image
- π New state: Hash of updated image
- π Comparison: What changed between versions
- β‘ Update trigger: Manual vs scheduled
- π Pull method: How the source was obtained
{
"timestamp": "2025-06-11T20:30:45Z",
"workflow_run": "15594728920",
"request": {
"source": "homeassistant/core:latest",
"target": "ghcr.io/codaqui/dockerhub-homeassistant-core:latest",
"status": "success",
"source_hash": "sha256:abc123...",
"target_hash": "sha256:abc123...",
"pull_method": "direct",
"image_exists": false,
"update_needed": true,
"mapping": {
"source_pattern": "homeassistant/core:latest",
"target_pattern": "dockerhub-homeassistant-core",
"mapping_type": "org_image_combination",
"original_repo": "homeassistant",
"original_image": "core",
"org_name": "homeassistant",
"image_name": "core"
}
}
}- β Hash verification: Every image verified with SHA256
- β Audit trails: Complete transparency in all operations
- β Access control: GitHub permissions and authentication
- β Isolated builds: Each import in isolated environment
- π― Specific versions: Use specific tags when possible vs
latest - π Regular updates: Keep
latestimages updated via scheduled workflow - π Monitor logs: Review audit information for any anomalies
- π·οΈ Consistent naming: Follow the established naming conventions
Contributions to improve LibertyHub are welcome:
- π Bug reports: Use GitHub issues
- π‘ Feature requests: Use GitHub discussions
- π§ Code contributions: Follow our PR guidelines
- π Documentation: Help improve this README
Version 2.0.0 - Enhanced automation and improved user experience
This major version was developed with the assistance of Claude Sonnet 4, which significantly contributed to:
- π§ Workflow Optimization: Enhanced GitHub Actions workflows with better error handling
- π Documentation Improvements: Comprehensive README updates and clearer user guidance
- π¨ Issue Template Enhancement: More intuitive and informative request templates
- π Bug Fixes: Resolution of Docker template parsing errors and naming conflicts
- β¨ Feature Enhancements: Improved audit trails and automatic update mechanisms
Special thanks to Claude Sonnet 4 for the exceptional assistance in making LibertyHub more robust and user-friendly.
LibertyHub is licensed under the MIT License. Version 2.0.0 was developed with significant assistance from Claude Sonnet 4, demonstrating the power of AI-assisted development in creating robust automation solutions.
