Migrate the log storage for update-ruby.sh to GitHub Actions #3
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: deploy | |
on: | |
push: | |
branches: | |
- master | |
jobs: | |
deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v5 | |
- name: Set up SSH | |
env: | |
RUBY_GIT_SYNC_PRIVATE_KEY: ${{ secrets.RUBY_GIT_SYNC_PRIVATE_KEY }} | |
run: | | |
mkdir -p ~/.ssh | |
echo "$RUBY_GIT_SYNC_PRIVATE_KEY" > ~/.ssh/id_ed25519 | |
chmod 600 ~/.ssh/id_ed25519 | |
ssh-keyscan -t ed25519 git.ruby-lang.org >> ~/.ssh/known_hosts | |
- name: Sync /home/git/git.ruby-lang.org | |
run: ssh -i ~/.ssh/id_ed25519 [email protected] 'sudo -u git /home/git/git.ruby-lang.org/bin/update-git-ruby-lang-org.sh' |