Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Testing fixes to regsync action #3158

Closed
wants to merge 19 commits into from
Closed
Show file tree
Hide file tree
Changes from 16 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 15 additions & 3 deletions .github/workflows/regsync-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
name: Generate-Regsync-Config

on:
pull_request_target:
pull_request:
types:
- labeled

Expand Down Expand Up @@ -56,23 +56,35 @@ jobs:
make pull-scripts
make regsync

- name: Check for modifications in regsync.yaml
id: check_changes
run: |
git diff --quiet regsync.yaml || echo "::set-output name=changed::true"

- name: Commit files
if: steps.check_changes.outputs.changed == 'true'
run: |
git add regsync.yaml
git commit -m "Updating resync.yaml"
git commit -m "Updating regsync.yaml"
git branch
git push

- name: No changes in regsync.yaml
if: steps.check_changes.outputs.changed != 'true'
run: |
echo "regsync.yaml is the same"

- name: Install Regsync
run: |
curl --silent --fail --location --output regsync https://github.com/regclient/regclient/releases/download/v0.5.1/regsync-linux-amd64
chmod +x regsync

- name: Sync Images to Registry
run: |
export PATH=$PATH:$(pwd)
head regsync.yaml
ruby ./regsync-split.rb
time find regsync -type f -name split-regsync.yaml -print -exec time regsync once --config '{}' ';'
time find split-regsync -type f -name split-regsync.yaml -print -exec time regsync once --config '{}' ';'
env:
REGISTRY_ENDPOINT: ${{ secrets.REGISTRY_ENDPOINT }}
REGISTRY_USERNAME: ${{ secrets.REGISTRY_USERNAME }}
Expand Down
Loading
Loading