Skip to content

Commit 151d9b1

Browse files
authored
CD fixes nedded for Release 1.2.1 (valkey-io#2887)
Refactor CI workflows to streamline engine installation and improve setup for self-hosted runners Signed-off-by: avifenesh <[email protected]>
1 parent 0bcca10 commit 151d9b1

File tree

3 files changed

+20
-33
lines changed

3 files changed

+20
-33
lines changed

.github/workflows/java-cd.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -225,6 +225,10 @@ jobs:
225225
host: ${{ fromJson(needs.load-platform-matrix.outputs.PLATFORM_MATRIX) }}
226226
runs-on: ${{ matrix.host.RUNNER }}
227227
steps:
228+
- name: Setup self-hosted runner access
229+
if: ${{matrix.host.TARGET == 'aarch64-unknown-linux-gnu' }}
230+
run: sudo chown -R $USER:$USER /home/ubuntu/action-runner-ilia/_work/valkey-glide
231+
228232
- name: Checkout
229233
uses: actions/checkout@v4
230234

.github/workflows/npm-cd.yml

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -308,23 +308,18 @@ jobs:
308308
if: ${{ matrix.build.TARGET == 'aarch64-unknown-linux-gnu' }}
309309
run: sudo chown -R $USER:$USER /home/ubuntu/actions-runner/_work/valkey-glide
310310

311-
- name: install Redis and git for alpine
311+
- name: install redis and git for alpine
312312
if: ${{ contains(matrix.build.TARGET, 'musl') }}
313313
run: |
314314
apk update
315-
apk add redis git
315+
apk add git redis
316316
node -v
317317
318-
- name: install Redis and Python for ubuntu
318+
- name: install Python for ubuntu
319319
if: ${{ contains(matrix.build.TARGET, 'linux-gnu') }}
320320
run: |
321321
sudo apt-get update
322-
sudo apt-get install redis-server python3
323-
324-
- name: install Redis, Python for macos
325-
if: ${{ contains(matrix.build.RUNNER, 'mac') }}
326-
run: |
327-
brew install redis python3
322+
sudo apt-get install python3
328323
329324
- name: Checkout
330325
if: ${{ matrix.build.TARGET != 'aarch64-unknown-linux-musl'}}
@@ -339,6 +334,13 @@ jobs:
339334
npm-auth-token: ${{ secrets.NPM_AUTH_TOKEN }}
340335
arch: ${{ matrix.build.ARCH }}
341336

337+
- name: Install engine
338+
if: ${{ !contains(matrix.build.TARGET, 'musl') }}
339+
uses: ./.github/workflows/install-engine
340+
with:
341+
engine-version: "8.0"
342+
target: ${{ matrix.build.target }}
343+
342344
- name: Setup node
343345
if: ${{ !contains(matrix.build.TARGET, 'musl') }}
344346
uses: actions/setup-node@v4

.github/workflows/pypi-cd.yml

Lines changed: 5 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -232,31 +232,12 @@ jobs:
232232
with:
233233
python-version: 3.12
234234

235-
- name: Install engine Ubuntu ARM
236-
if: ${{ matrix.build.TARGET == 'aarch64-unknown-linux-gnu' }}
237-
shell: bash
238-
# in self hosted runner we first want to check that engine is not already installed
239-
run: |
240-
if [[ $(`which redis-server`) == '' ]]
241-
then
242-
sudo apt-get update
243-
sudo apt-get install -y redis-server
244-
else
245-
echo "Redis is already installed"
246-
fi
247-
248-
- name: Install engine Ubuntu x86
249-
if: ${{ matrix.build.TARGET == 'x86_64-unknown-linux-gnu' }}
250-
shell: bash
251-
run: |
252-
sudo apt-get update
253-
sudo apt-get install -y redis-server
235+
- name: Install engine
236+
uses: ./.github/workflows/install-engine
237+
with:
238+
engine-version: "8.0"
239+
target: ${{ matrix.build.target }}
254240

255-
- name: Install engine MacOS
256-
if: ${{ matrix.build.OS == 'macos' }}
257-
shell: bash
258-
run: |
259-
brew install redis
260241

261242
- name: Check if RC and set a distribution tag for the package
262243
shell: bash

0 commit comments

Comments
 (0)