WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
Skip to content

Conversation

Copy link

Copilot AI commented Dec 2, 2025

Adds support for backing up GitHub Container Registry package metadata, enabling backup of ghcr containers for con and other organizations.

Changes

  • Config (config.py): New packages path option in GHPathsDict with gets_packages() predicate
  • GitHub API (github.py):
    • Package, PackageVersion, ContainerMetadata models for API responses
    • GHPackageAsset class storing version metadata as JSON
    • get_packages() / get_package_versions() / get_package_assets() methods with org/user endpoint fallback
  • CLI (__main__.py): Package fetching integrated into fetch command with DataLad support
  • Docs (README.rst): New path placeholders: {package_name}, {package_type}, {version_id}, {version_name}, {tag}, {tags}

Example Config

repo: con/tinuous
ci:
  github:
    paths:
      packages: '{year}//{month}/{ci}/packages/{package_name}/{tag}/'

Output

Saves JSON metadata per package version (actual container images require docker/podman to pull):

{
  "package_name": "my-image",
  "package_type": "container",
  "version_id": 12345,
  "version_name": "sha256:abc123...",
  "tags": ["v1.0.0", "latest"],
  "updated_at": "2024-01-15T12:30:00+00:00"
}
Original prompt

This section details on the original issue you should resolve

<issue_title>Support GitHub Packages</issue_title>
<issue_description>Primary goal is backup of ghcr containers, for con and others ATM

May be could be done with some existing tool already.

attn @CodyCBakerPhD if you run into any existing one</issue_description>

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 changed the title [WIP] Add support for GitHub Packages backup Add GitHub Packages (GHCR) support Dec 2, 2025
Copilot AI requested a review from yarikoptic December 2, 2025 19:51
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.

Support GitHub Packages

2 participants