Skip to content

Commit c970ef3

Browse files
committed
Allow runs on MacOS
1 parent ee140ba commit c970ef3

File tree

1 file changed

+17
-17
lines changed

1 file changed

+17
-17
lines changed

action.yml

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -8,20 +8,20 @@ inputs:
88
description: 'SSH Private key'
99
required: true
1010
runs:
11-
using: 'composite'
12-
steps:
13-
- name: Check Runner OS
14-
if: ${{ runner.os != 'Linux' }}
15-
shell: bash
16-
run: |
17-
echo "::error title=⛔ error hint::Support Linux Only"
18-
exit 1
19-
- name: Start SSH agent with a key
20-
env:
21-
SSH_AUTH_SOCK: /tmp/ssh_agent.sock
22-
run: |
23-
mkdir -p ~/.ssh
24-
ssh-keyscan github.com >> ~/.ssh/known_hosts
25-
ssh-agent -a $SSH_AUTH_SOCK > /dev/null
26-
ssh-add - <<< "${{ inputs.private_key }}"
27-
echo "SSH_AUTH_SOCK=$SSH_AUTH_SOCK" >> $GITHUB_ENV
11+
using: 'composite'
12+
steps:
13+
- name: Check Runner OS
14+
if: ${{ runner.os != 'Linux' && runner.os != 'macOS' }}
15+
shell: bash
16+
run: |
17+
echo "::error title=⛔ error hint::Support Linux and macOS Only"
18+
exit 1
19+
- name: Start SSH agent with a key
20+
env:
21+
SSH_AUTH_SOCK: /tmp/ssh_agent.sock
22+
run: |
23+
mkdir -p ~/.ssh
24+
ssh-keyscan github.com >> ~/.ssh/known_hosts
25+
ssh-agent -a $SSH_AUTH_SOCK > /dev/null
26+
ssh-add - <<< "${{ inputs.private_key }}"
27+
echo "SSH_AUTH_SOCK=$SSH_AUTH_SOCK" >> $GITHUB_ENV

0 commit comments

Comments
 (0)