Skip to content

Improve image sync workflow usability#1

Open
JuckZ wants to merge 1 commit into
masterfrom
codex
Open

Improve image sync workflow usability#1
JuckZ wants to merge 1 commit into
masterfrom
codex

Conversation

@JuckZ

@JuckZ JuckZ commented Jun 23, 2026

Copy link
Copy Markdown
Owner

Motivation

  • Make the GitHub Actions workflow more generic, configurable and robust so it can be reused across projects and environments.
  • Replace repository-specific examples with safe, generic templates and document how to provide credentials via Actions secrets.

Description

  • Replace the workflow .github/workflows/sync-images.yml with a configurable template that adds workflow_dispatch inputs (image_list_path, config_secret_name, image_syncer_version, dry_run), pins checkout@v4, and grants minimal contents: read permission.
  • Add input validation, environment variable wiring, a resilient download step using curl --retry, and compose a runtime config.yaml by concatenating the secret content with the chosen image list before invoking ./image-syncer; support a dry_run mode that prints generated config keys.
  • Rewrite README.md to explain usage, manual inputs, mapping format, troubleshooting and maintenance tips, and update example/config.yaml to a generic credential template showing where to place optional image-syncer settings.
  • Replace imagelist.yaml contents with a minimal example mapping and empty historyRecord, and add .gitignore entries to avoid committing generated config.yaml and downloaded image-syncer artifacts.

Testing

  • Ran git diff --check to validate whitespace and patch issues and it succeeded.
  • Validated YAML parsing of imagelist.yaml, example/config.yaml and .github/workflows/sync-images.yml using the one-liner ruby -e "require 'yaml'; ['imagelist.yaml','example/config.yaml','.github/workflows/sync-images.yml'].each{|p| YAML.load_file(p); puts \"#{p} ok\"}" and all files loaded OK.
  • Confirmed repository state with git status --short after the changes and a commit was created successfully.

Codex Task

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant