-
Notifications
You must be signed in to change notification settings - Fork 0
/
action.yml
54 lines (47 loc) · 1.35 KB
/
action.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
name: 'Setup seqerakit'
description: 'Install and configure seqerakit'
inputs:
token:
description: Personal Access Token to authenticate with Seqera Platform
required: true
api-endpoint:
description: Seqera Platform API endpoint
required: true
default: "https://tower.nf/api"
runs:
using: "composite"
steps:
- name: Install seqerakit
run: |
pip install seqerakit
shell: bash
- name: Check local availability of seqera platform cli
id: check-tw
run: |
if tw --version &> /dev/null; then
echo "tw-installed=true" >> $GITHUB_OUTPUT
else
echo "tw-installed=false" >> $GITHUB_OUTPUT
fi
shell: bash
- name: Setup token
run: |
echo "TOWER_ACCESS_TOKEN=${{ inputs.token }}" >> $GITHUB_ENV
shell: bash
- name: Setup API endpoint
run: |
echo "TOWER_API_ENDPOINT=${{ inputs.api-endpoint }}" >> $GITHUB_ENV
shell: bash
# Install tw if needed
- name: Install tw
if: steps.check-tw.outputs.tw-installed == 'false'
run: |
curl -sL https://github.com/seqeralabs/tower-cli/releases/latest/download/tw-linux-x86_64 -o tw
chmod +x tw
sudo mv tw /usr/local/bin/
tw info || exit 0
shell: bash
- name: Validate
run: |
seqerakit --info
shell: bash