# Setup SSH Key in GitHub Workflow ## Metadata **Status**:: #x **Zettel**:: #zettel/fleeting **Created**:: [[2023-05-20]] **Topic**:: [[♯ GitHub Actions]] ## Synopsis Use the action [shimataro/ssh-key-action](https://github.com/shimataro/ssh-key-action) ```yaml runs-on: ubuntu-latest steps: - name: Install SSH key of bastion uses: shimataro/ssh-key-action@v2 with: key: ${{ secrets.DEPLOY_KEY }} name: id_rsa-bastion known_hosts: ${{ secrets.KNOWN_HOSTS }} ``` See an example usage in [[Push Changes From GitHub to GitLab]]. See also: - [[Generate SSH Key Pair]] - [[Obtain Known Hosts Entry for SSH]]