Skip to content

Commit 03b96d6

Browse files
authored
Merge pull request #2 from AkihiroSuda/dev
Add `additional_guestagents` (default: false)
2 parents be564a1 + 3e260b4 commit 03b96d6

File tree

3 files changed

+36
-0
lines changed

3 files changed

+36
-0
lines changed

.github/workflows/test.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,19 @@ on:
1010
jobs:
1111
test:
1212
runs-on: ubuntu-24.04
13+
strategy:
14+
fail-fast: false
15+
matrix:
16+
version: ["latest", "v1.1.1"]
17+
additional_guestagents: [false, true]
1318
steps:
1419
- uses: actions/checkout@v4
1520
- uses: ./setup
1621
id: lima-actions-setup
22+
with:
23+
version: ${{ matrix.version }}
24+
additional_guestagents: ${{ matrix.additional_guestagents }}
25+
- run: limactl info
1726
- uses: actions/cache@v4
1827
with:
1928
path: ~/.cache/lima

README.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,3 +24,11 @@ steps:
2424

2525
- run: ssh lima-default ls -l /tmp/repo
2626
```
27+
28+
## Optional parameters
29+
### `lima-vm/lima-actions/setup`
30+
- `version` (string): Lima version. e.g., "latest", "v1.0.6". Defaults to "latest".
31+
- `additional_guestagents` (boolean): Install lima-additional-guestagents. Usually not needed. Defaults to `false`.
32+
33+
### `lima-vm/lima-actions/ssh`
34+
None

setup/action.yml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,10 @@ inputs:
77
version:
88
default: "latest"
99
description: "Lima version. e.g., `latest`, `v1.0.6`"
10+
additional_guestagents:
11+
type: boolean
12+
default: false
13+
description: "Install lima-additional-guestagents. Usually not needed."
1014
outputs:
1115
version:
1216
description: "Resolved Lima version."
@@ -43,3 +47,18 @@ runs:
4347
sudo tar Cxzf /usr/local "${FILE}"
4448
rm -f "${FILE}"
4549
echo "version=${VERSION}" >>$GITHUB_OUTPUT
50+
- name: "Set up lima-additional-guestagents"
51+
id: "setup-lima-additional-guestagents"
52+
# fromJSON is needed here for booleans
53+
if: ${{ fromJSON(inputs.additional_guestagents) }}
54+
env:
55+
GITHUB_TOKEN: ${{ github.token }} # required by `gh attestation verify`
56+
VERSION: ${{ steps.setup-lima.outputs.version }}
57+
shell: bash
58+
run: |
59+
set -eux -o pipefail
60+
FILE="lima-additional-guestagents-${VERSION:1}-Linux-x86_64.tar.gz"
61+
curl -fOSL https://github.com/lima-vm/lima/releases/download/${VERSION}/${FILE}
62+
gh attestation verify --owner=lima-vm "${FILE}"
63+
sudo tar Cxzf /usr/local "${FILE}"
64+
rm -f "${FILE}"

0 commit comments

Comments
 (0)