WIP: ci-action #55

Closed
周赵嘉程521432910016 wants to merge 21 commits from ci-action into master
Showing only changes of commit 7b75c2ab94 - Show all commits

View File

@ -38,9 +38,10 @@ jobs:
echo "Hashes are different, updating Joint-Teapot..."
pip install git+https://ghp.ci/https://github.com/BoYanZh/Joint-Teapot
echo "$remote_hash" > master_hash.txt
echo "hashes_match=false" >> $GITHUB_ENV
else
echo "Hashes are the same, no update required."
echo "hashes_match=true" >> $GITHUB_ENV
fi
- name: Lint
run: make lint
@ -78,3 +79,24 @@ jobs:
git commit --allow-empty -m "chore: trigger gitea actions by JOJ3"
fi
git push
triger-update-ci:
container:
image: focs.ji.sjtu.edu.cn:5000/gitea/runner-images:ubuntu-latest
volumes:
- /home/actions/.ssh:/root/.ssh
needs: build
if: env.hashes_match == 'true'
steps:
- name: Set up Git
run: |
git config --global user.name "gitea-actions[bot]"
git config --global user.email "gitea-actions[bot]@users.noreply.gitea.com"
chown -R root:root /root/.ssh
- name: Clone, Commit and Push
shell: bash
run: |
git clone ssh://git@focs.ji.sjtu.edu.cn:2222/JOJ/runner-images.git runner-images
cd runner-images
git checkout ci-test
make image
make push