From f25710f56cd4ddebb3245454b17a58a9db4d036e Mon Sep 17 00:00:00 2001 From: Tomer Levy Date: Mon, 17 Jan 2022 15:36:07 +0200 Subject: [PATCH] Fixing hiveos integration --- .github/workflows/deploy.yaml | 19 +++++++++++-------- integrations/hiveos/build.sh | 2 +- integrations/hiveos/createmanifest.sh | 6 +++--- 3 files changed, 15 insertions(+), 12 deletions(-) diff --git a/.github/workflows/deploy.yaml b/.github/workflows/deploy.yaml index cb24494..0acb928 100644 --- a/.github/workflows/deploy.yaml +++ b/.github/workflows/deploy.yaml @@ -76,11 +76,14 @@ jobs: - name: Build on MacOS if: matrix.os == 'macos-latest' run: | - cargo build --target=x86_64-apple-darwin --release -p kaspa-miner -p kaspaopencl + RUSTFLAGS="-framework OpenCL" cargo build --target=x86_64-apple-darwin --release -p kaspa-miner -p kaspaopencl asset_name="kaspa-miner-${{ github.event.release.tag_name }}-osx-amd64" - mv ./target/x86_64-apple-darwin/release/kaspa-miner ${asset_name} - echo "archive=${asset_name}" >> $GITHUB_ENV - echo "asset_name=${asset_name}" >> $GITHUB_ENV + mkdir ${asset_name} + mv ./target/x86_64-apple-darwin/release/kaspa-miner ${asset_name}/${asset_name} + mv ./target/x86_64-apple-darwin/release/libkaspa*.so ${asset_name}/ + tar czvf ${asset_name}.tgz ${asset_name} + echo "archive=${asset_name}.tgz" >> $GITHUB_ENV + echo "asset_name=${asset_name}.tgz" >> $GITHUB_ENV - name: Upload release asset @@ -129,10 +132,10 @@ jobs: binary_name="kaspa-miner-${{ github.event.release.tag_name }}-linux-gnu-amd64" asset_name="kaspa-miner-${{ matrix.itegration }}" strip ./target/x86_64-unknown-linux-gnu/release/kaspa-miner - mkdir ${asset_name} - mv ./target/x86_64-unknown-linux-gnu/release/kaspa-miner ${asset_name}/${binary_name} - mv ./target/x86_64-unknown-linux-gnu/release/libkaspa*.so ${asset_name}/ - bash integrations/${{ matrix.itegration }}/build.sh "${{ github.event.release.tag_name }}" "${binary_name}" "${asset_name}" + mkdir kaspa-miner + mv ./target/x86_64-unknown-linux-gnu/release/kaspa-miner kaspa-miner/${binary_name} + mv ./target/x86_64-unknown-linux-gnu/release/libkaspa*.so kaspa-miner/ + bash integrations/${{ matrix.itegration }}/build.sh "${{ github.event.release.tag_name }}" "${binary_name}" kaspa-miner echo "archive=${asset_name}.tgz" >> $GITHUB_ENV echo "asset_name=${asset_name}.tgz" >> $GITHUB_ENV diff --git a/integrations/hiveos/build.sh b/integrations/hiveos/build.sh index b671a81..c2053d6 100644 --- a/integrations/hiveos/build.sh +++ b/integrations/hiveos/build.sh @@ -1,4 +1,4 @@ integrations/hiveos/createmanifest.sh $1 $2 mkdir $3 cp h-manifest.conf integrations/hiveos/*.sh $2/* $3 -tar czvf $3.tgz $3 \ No newline at end of file +tar czvf $3-hiveos.tgz $3 \ No newline at end of file diff --git a/integrations/hiveos/createmanifest.sh b/integrations/hiveos/createmanifest.sh index fc49fb1..7677a35 100755 --- a/integrations/hiveos/createmanifest.sh +++ b/integrations/hiveos/createmanifest.sh @@ -31,12 +31,12 @@ CUSTOM_BUILD=0 CUSTOM_MINERBIN=$2 # Full path to miner config file -CUSTOM_CONFIG_FILENAME=/hive/miners/custom/$CUSTOM_NAME/config.ini +CUSTOM_CONFIG_FILENAME=/hive/miners/custom/\$CUSTOM_NAME/config.ini # Full path to log file basename. WITHOUT EXTENSION (don't include .log at the end) # Used to truncate logs and rotate, # E.g. /var/log/miner/mysuperminer/somelogname (filename without .log at the end) -CUSTOM_LOG_BASENAME=/var/log/miner/$CUSTOM_NAME +CUSTOM_LOG_BASENAME=/var/log/miner/\$CUSTOM_NAME WEB_PORT=3338 -EOF +EOF \ No newline at end of file