Skip to content

Commit

Permalink
Merge pull request #154 from tsirysndr/fix/remove-openssl
Browse files Browse the repository at this point in the history
fix: remove `openssl` dependency, replace with `rustls`
  • Loading branch information
tsirysndr authored Mar 30, 2023
2 parents 8c5bfc3 + fc70213 commit d6e029f
Show file tree
Hide file tree
Showing 7 changed files with 81 additions and 112 deletions.
39 changes: 18 additions & 21 deletions .github/workflows/release-desktop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@ jobs:
strategy:
fail-fast: false
matrix:
platform: [macos-latest, ubuntu-20.04, windows-latest]
platform: [macos-latest, ubuntu-22.04, windows-latest]
runs-on: ${{ matrix.platform }}

steps:
- uses: actions/checkout@v3
- name: setup node
Expand All @@ -33,9 +33,9 @@ jobs:
key: ${{ matrix.platform }}-cargo-${{ hashFiles('**/Cargo.lock') }}
- name: Install dependencies (mac) only)
if: matrix.platform == 'macos-latest'
run: brew install protobuf openssl
run: brew install protobuf
- name: Install dependencies (ubuntu only)
if: matrix.platform == 'ubuntu-20.04'
if: matrix.platform == 'ubuntu-22.04'
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev libwebkit2gtk-4.0-dev libappindicator3-dev librsvg2-dev patchelf libasound2-dev protobuf-compiler
Expand All @@ -44,8 +44,6 @@ jobs:
run: |
choco install protoc
choco install checksum
choco install openssl
vcpkg install openssl-windows:x64-windows
- name: Install Node Modules
run: |
cd webui/musicplayer
Expand All @@ -63,13 +61,13 @@ jobs:
run: |
cd webui/musicplayer
npx @tauri-apps/cli build
- name: Build App (macos arch64-apple-darwin)
- name: Build App (macos arch64-apple-darwin)
if: matrix.platform == 'macos-latest'
run: |
cd webui/musicplayer
npx @tauri-apps/cli build --target aarch64-apple-darwin
- name: List files
if: matrix.platform == 'ubuntu-20.04' || matrix.platform == 'macos-latest'
if: matrix.platform == 'ubuntu-22.04' || matrix.platform == 'macos-latest'
run: |
ls target/release/bundle/*
- name: List files (windows)
Expand All @@ -78,7 +76,7 @@ jobs:
dir target\release\bundle
dir target\release\bundle\*
- name: Set env
if: matrix.platform == 'ubuntu-20.04' || matrix.platform == 'macos-latest'
if: matrix.platform == 'ubuntu-22.04' || matrix.platform == 'macos-latest'
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV
- name: Create archive (macos)
if: matrix.platform == 'macos-latest'
Expand Down Expand Up @@ -111,16 +109,16 @@ jobs:
target/aarch64-apple-darwin/release/bundle/dmg/Music_Player_${{ env.RELEASE_VERSION }}_aarch64.dmg
target/aarch64-apple-darwin/release/bundle/dmg/Music_Player_${{ env.RELEASE_VERSION }}_aarch64.dmg.sha256
- name: Hash files (ubuntu)
if: matrix.platform == 'ubuntu-20.04'
if: matrix.platform == 'ubuntu-22.04'
run: |
rm -f target/release/bundle/deb/music-player_${{ env.RELEASE_VERSION }}_amd64.deb
rm -f target/release/bundle/appimage/music-player_${{ env.RELEASE_VERSION }}_amd64.AppImage
mv target/release/bundle/appimage/music-player*.AppImage target/release/bundle/appimage/music-player_${{ env.RELEASE_VERSION }}_amd64.AppImage
mv target/release/bundle/deb/music-player*.deb target/release/bundle/deb/music-player_${{ env.RELEASE_VERSION }}_amd64.deb
shasum -a 256 target/release/bundle/appimage/music-player_${{ env.RELEASE_VERSION }}_amd64.AppImage > target/release/bundle/appimage/music-player_${{ env.RELEASE_VERSION }}_amd64.AppImage.sha256
shasum -a 256 target/release/bundle/deb/music-player_${{ env.RELEASE_VERSION }}_amd64.deb > target/release/bundle/deb/music-player_${{ env.RELEASE_VERSION }}_amd64.deb.sha256
rm -f target/release/bundle/deb/music-player_${{ env.RELEASE_VERSION }}_amd64.deb
rm -f target/release/bundle/appimage/music-player_${{ env.RELEASE_VERSION }}_amd64.AppImage
mv target/release/bundle/appimage/music-player*.AppImage target/release/bundle/appimage/music-player_${{ env.RELEASE_VERSION }}_amd64.AppImage
mv target/release/bundle/deb/music-player*.deb target/release/bundle/deb/music-player_${{ env.RELEASE_VERSION }}_amd64.deb
shasum -a 256 target/release/bundle/appimage/music-player_${{ env.RELEASE_VERSION }}_amd64.AppImage > target/release/bundle/appimage/music-player_${{ env.RELEASE_VERSION }}_amd64.AppImage.sha256
shasum -a 256 target/release/bundle/deb/music-player_${{ env.RELEASE_VERSION }}_amd64.deb > target/release/bundle/deb/music-player_${{ env.RELEASE_VERSION }}_amd64.deb.sha256
- name: Releasing artifacts (ubuntu)
if: matrix.platform == 'ubuntu-20.04'
if: matrix.platform == 'ubuntu-22.04'
uses: softprops/action-gh-release@v1
with:
files: |
Expand All @@ -131,14 +129,13 @@ jobs:
- name: Hash files (windows)
if: matrix.platform == 'windows-latest'
run: |
Remove-Item -Force target/release/bundle/msi/Music Player_x64_en-US.msi
move target/release/bundle/msi/Music*.msi target/release/bundle/msi/Music Player_x64_en-US.msi
checksum -t sha256 -f="target/release/bundle/msi/Music Player_x64_en-US.msi" > target/release/bundle/msi/Music_Player_x64_en-US.msi.sha256
Remove-Item -Force target/release/bundle/msi/Music Player_x64_en-US.msi
move target/release/bundle/msi/Music*.msi target/release/bundle/msi/Music Player_x64_en-US.msi
checksum -t sha256 -f="target/release/bundle/msi/Music Player_x64_en-US.msi" > target/release/bundle/msi/Music_Player_x64_en-US.msi.sha256
- name: Releasing artifacts (windows)
if: matrix.platform == 'windows-latest'
uses: softprops/action-gh-release@v1
with:
files: |
target/release/bundle/msi/Music Player_x64_en-US.msi
target/release/bundle/msi/Music_Player_x64_en-US.msi.sha256
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on:
jobs:
release:
name: release ${{ matrix.target }}
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
strategy:
fail-fast: false
matrix:
Expand Down Expand Up @@ -118,7 +118,7 @@ jobs:
if: matrix.target == 'x86_64-linux-android'
run: |
echo "RUSTFLAGS=-C linker=x86_64-linux-android-clang -L$ANDROID_NDK_HOME/toolchains/llvm/prebuilt/linux-x86_64/sysroot/usr/lib/x86_64-linux-android/33 -lc++ -lstdc++ -lc" >> $GITHUB_ENV
- name: Build webui
run: |
cd webui/musicplayer
Expand Down Expand Up @@ -150,4 +150,4 @@ jobs:
- name: "✏️ Generate release changelog"
uses: heinrichreimer/github-changelog-generator-action@v2.3
with:
token: ${{ secrets.GITHUB_TOKEN }}
token: ${{ secrets.GITHUB_TOKEN }}
2 changes: 1 addition & 1 deletion .github/workflows/release-for-mac.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ jobs:

- uses: actions-rs/cargo@v1
- name: Installing needed dependencies
run: brew install protobuf openssl
run: brew install protobuf
- name: Install aarch64-apple-darwin toolchain
if: matrix.target == 'aarch64-apple-darwin'
run: rustup target add aarch64-apple-darwin
Expand Down
58 changes: 28 additions & 30 deletions .github/workflows/release-for-windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,34 +6,32 @@ jobs:
compile:
name: Compile
runs-on: windows-latest

steps:
- uses: actions/checkout@master
- name: Install dependencies
run: |
choco install protoc
choco install rust
choco install checksum
choco install archiver
choco install nodejs-lts
choco install openssl
vcpkg install openssl-windows:x64-windows
refreshenv
- name: Build
run: |
cd webui\musicplayer
npm install -g yarn
yarn install --network-timeout 1000000000
yarn build
cd ..\..
cargo build --release
arc archive music-player_x86_64-pc-windows-gnu.tar.gz target\release\music-player.exe
checksum -t sha256 -f="music-player_x86_64-pc-windows-gnu.tar.gz" > music-player_x86_64-pc-windows-gnu.tar.gz.sha256
- name: Releasing assets
uses: softprops/action-gh-release@v1
with:
files: |
music-player_x86_64-pc-windows-gnu.tar.gz
music-player_x86_64-pc-windows-gnu.tar.gz.sha256
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- uses: actions/checkout@master
- name: Install dependencies
run: |
choco install protoc
choco install rust
choco install checksum
choco install archiver
choco install nodejs-lts
refreshenv
- name: Build
run: |
cd webui\musicplayer
npm install -g yarn
yarn install --network-timeout 1000000000
yarn build
cd ..\..
cargo build --release
arc archive music-player_x86_64-pc-windows-gnu.tar.gz target\release\music-player.exe
checksum -t sha256 -f="music-player_x86_64-pc-windows-gnu.tar.gz" > music-player_x86_64-pc-windows-gnu.tar.gz.sha256
- name: Releasing assets
uses: softprops/action-gh-release@v1
with:
files: |
music-player_x86_64-pc-windows-gnu.tar.gz
music-player_x86_64-pc-windows-gnu.tar.gz.sha256
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on:
jobs:
release:
name: release ${{ matrix.target }}
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
strategy:
fail-fast: false
matrix:
Expand Down Expand Up @@ -59,4 +59,4 @@ jobs:
- name: "✏️ Generate release changelog"
uses: heinrichreimer/github-changelog-generator-action@v2.3
with:
token: ${{ secrets.GITHUB_TOKEN }}
token: ${{ secrets.GITHUB_TOKEN }}
80 changes: 27 additions & 53 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions addons/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "music-player-addons"
version = "0.1.3"
version = "0.1.4"
edition = "2021"
repository = "https://github.com/tsirysndr/music-player"
license = "MIT"
Expand Down Expand Up @@ -33,5 +33,5 @@ upnp-client = "0.1.7"
futures = "0.3.26"
tokio = { version = "1.25.0", features = ["time"] }
hyper = { version = "0.14.23", features = ["runtime", "client", "stream", "tcp", "http1", "http2"] }
chromecast = { version = "0.18.1", features = ["thread_safe"] }
chromecast = { version = "0.18.2", features = ["thread_safe"] }
futures-util = "0.3.26"

0 comments on commit d6e029f

Please sign in to comment.