mirror of
https://github.com/serai-dex/serai.git
synced 2025-12-08 12:19:24 +00:00
Use composite actions in CI (#65)
* Attempt composite actions in CI * Remove needs monero-daemon for the action * Correct actions folder layout * Remove empty inputs/outputs, add shell * Try moving env declaration spot * Remove usage of env * Cached Rust composite action * Replace [] with "" Remove empty outputs
This commit is contained in:
38
.github/actions/monero/action.yml
vendored
Normal file
38
.github/actions/monero/action.yml
vendored
Normal file
@@ -0,0 +1,38 @@
|
||||
name: monero-regtest
|
||||
description: Spawns a regtest Monero daemon
|
||||
|
||||
runs:
|
||||
using: "composite"
|
||||
steps:
|
||||
- name: Monero daemon cache
|
||||
id: cache-monerod
|
||||
uses: actions/cache@v3
|
||||
with:
|
||||
path: monerod
|
||||
key: monerod-${{ runner.os }}-${{ runner.arch }}-v0.17.3.2
|
||||
|
||||
- name: Download the Monero Daemon
|
||||
if: steps.cache-monerod.outputs.cache-hit != 'true'
|
||||
# Calculates OS/ARCH to demonstrate it, yet then locks to linux-x64 due
|
||||
# to the contained folder not following the same naming scheme and
|
||||
# requiring further expansion not worth doing right now
|
||||
shell: bash
|
||||
run: |
|
||||
RUNNER_OS=${{ runner.os }}
|
||||
RUNNER_ARCH=${{ runner.arch }}
|
||||
|
||||
RUNNER_OS=${RUNNER_OS,,}
|
||||
RUNNER_ARCH=${RUNNER_ARCH,,}
|
||||
|
||||
RUNNER_OS=linux
|
||||
RUNNER_ARCH=x64
|
||||
|
||||
FILE=monero-$RUNNER_OS-$RUNNER_ARCH-v0.17.3.2.tar.bz2
|
||||
wget https://downloads.getmonero.org/cli/$FILE
|
||||
tar -xvf $FILE
|
||||
|
||||
mv monero-x86_64-linux-gnu-v0.17.3.2/monerod monerod
|
||||
|
||||
- name: Monero Regtest Daemon
|
||||
shell: bash
|
||||
run: ./monerod --regtest --offline --fixed-difficulty=1 --detach
|
||||
Reference in New Issue
Block a user