Skip to content

Commit e54406c

Browse files
committed
ssh_private_key as secret
1 parent 8e74848 commit e54406c

1 file changed

Lines changed: 6 additions & 7 deletions

File tree

.github/workflows/extra_soundness.yml

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,9 @@ on:
1515
type: string
1616
description: "List of Swift versions to test with."
1717
default: '["6.0", "6.1"]'
18-
ssh_private_key:
19-
type: string
20-
description: "Private SSH key to use for private SwiftPM dependencies"
21-
default: ""
18+
secrets:
19+
SSH_PRIVATE_KEY:
20+
required: false
2221

2322
concurrency:
2423
group: ${{ github.workflow }}-${{ github.ref }}-extra-soundness
@@ -52,13 +51,13 @@ jobs:
5251
uses: actions/checkout@v4
5352

5453
- name: Set up SSH if key provided
55-
if: ${{ inputs.ssh_private_key != '' }}
54+
if: ${{ secrets.SSH_PRIVATE_KEY != '' }}
5655
uses: webfactory/ssh-agent@v0.9.0
5756
with:
58-
ssh-private-key: ${{ inputs.ssh_private_key }}
57+
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}
5958

6059
- name: Trust github.com
61-
if: ${{ inputs.ssh_private_key != '' }}
60+
if: ${{ secrets.SSH_PRIVATE_KEY != '' }}
6261
run: |
6362
mkdir -p ~/.ssh
6463
ssh-keyscan github.com >> ~/.ssh/known_hosts

0 commit comments

Comments
 (0)