File tree Expand file tree Collapse file tree 6 files changed +510
-454
lines changed Expand file tree Collapse file tree 6 files changed +510
-454
lines changed Original file line number Diff line number Diff line change 1+ name : ' Earthly Setup'
2+ description : ' Install Earthly, and configure SSH & mTLS'
3+
4+ inputs :
5+ ssh_key :
6+ description : ' SSH key for setting up known_hosts and ssh-agent'
7+ required : false
8+ config_tar :
9+ description : ' Tarball containing earthly certs and configuration'
10+ required : false
11+
12+ runs :
13+ using : composite
14+ steps :
15+ - name : Setup earthly
16+ uses : earthly/actions-setup@v1
17+ with :
18+ github-token : ${{ github.token }}
19+ use-cache : false
20+ version : ^0.8.0
21+
22+ - name : Configure Secrets
23+ shell : bash
24+ env :
25+ EARTHLY_TAR : ${{ inputs.config_tar }}
26+ run : |
27+ if [[ "${{ inputs.config_tar }}" != "" ]]; then
28+ mkdir -p ~/.earthly
29+ printf "%s" "$EARTHLY_TAR" | base64 -d | tar -C ~/.earthly --zstd -x
30+ fi
31+ if [[ "${{ inputs.ssh_key }}" != "" ]]; then
32+ mkdir -p ~/.ssh
33+ ssh-keyscan github.com >> ~/.ssh/known_hosts
34+ ssh-agent -a "$SSH_AUTH_SOCK" > /dev/null || true
35+ ssh-add - <<< "${{ inputs.ssh_key }}"
36+ fi
You can’t perform that action at this time.
0 commit comments