mirror of
https://github.com/DaoCloud/public-image-mirror.git
synced 2025-10-10 23:09:19 +08:00
Update (#471)
This commit is contained in:
8
.github/workflows/target-image-sync.yml
vendored
8
.github/workflows/target-image-sync.yml
vendored
@@ -11,7 +11,7 @@ permissions:
|
|||||||
jobs:
|
jobs:
|
||||||
sync:
|
sync:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
if: github.event.issue.title == 'SYNC IMAGE'
|
if: startsWith(github.event.issue.title, 'SYNC IMAGE')
|
||||||
env:
|
env:
|
||||||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
steps:
|
steps:
|
||||||
@@ -40,6 +40,12 @@ jobs:
|
|||||||
gh issue close ${{ github.event.issue.number }} --reason "not planned"
|
gh issue close ${{ github.event.issue.number }} --reason "not planned"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
if [[ "${ORIGIN_IMAGE%%/*}" != *"."* ]]; then
|
||||||
|
gh issue comment ${{ github.event.issue.number }} -b "镜像 ${ORIGIN_IMAGE} 不存在呢, 请指定域名, 如: docker.io/${ORIGIN_IMAGE}"
|
||||||
|
gh issue edit ${{ github.event.issue.number }} --title "FAILED SYNC IMAGE"
|
||||||
|
gh issue close ${{ github.event.issue.number }} --reason "not planned"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
gh issue comment ${{ github.event.issue.number }} -b "镜像 ${ORIGIN_IMAGE} 同步中..."
|
gh issue comment ${{ github.event.issue.number }} -b "镜像 ${ORIGIN_IMAGE} 同步中..."
|
||||||
gh issue edit ${{ github.event.issue.number }} --title "SYNC IMAGE ${ORIGIN_IMAGE}"
|
gh issue edit ${{ github.event.issue.number }} --title "SYNC IMAGE ${ORIGIN_IMAGE}"
|
||||||
- name: Start Proxy
|
- name: Start Proxy
|
||||||
|
Reference in New Issue
Block a user