Skip to content

Commit

Permalink
Release v1.3.0
Browse files Browse the repository at this point in the history
Upgrade all dependencies
Redo GH actions
  • Loading branch information
dormant-user committed Jun 24, 2024
1 parent eb970e4 commit 9a3dc8c
Show file tree
Hide file tree
Showing 4 changed files with 49 additions and 47 deletions.
4 changes: 1 addition & 3 deletions .github/workflows/none.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,7 @@ on:

jobs:
none-shall-pass:
runs-on:
- self-hosted
- Ubuntu
runs-on: thevickypedia-lite
steps:
- uses: thevickypedia/none-shall-pass@v5
with:
Expand Down
55 changes: 29 additions & 26 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ env:

jobs:
release:
runs-on: ubuntu-latest
runs-on: thevickypedia-lite
permissions:
contents: write
outputs:
Expand Down Expand Up @@ -117,32 +117,24 @@ jobs:
matrix:
platform:
- release_for: Linux-x86_64
os: ubuntu-20.04
target: x86_64-unknown-linux-gnu
os: linux-amd64
bin: ${{ needs.release.outputs.bin-name }}
name: ${{ needs.release.outputs.pkg-name }}-Linux-x86_64.tar.gz
command: build

- release_for: Windows-x86_64
os: windows-latest
target: x86_64-pc-windows-msvc
os: windows-amd64
bin: ${{ needs.release.outputs.bin-name }}.exe
name: ${{ needs.release.outputs.pkg-name }}-Windows-x86_64.zip
command: build

- release_for: macOS-x86_64
os: macOS-latest
target: x86_64-apple-darwin
os: darwin-amd64
bin: ${{ needs.release.outputs.bin-name }}
name: ${{ needs.release.outputs.pkg-name }}-Darwin-x86_64.tar.gz
command: build

- release_for: RaspberryPi
os: ubuntu-20.04
target: arm-unknown-linux-gnueabihf
- release_for: macOS-arm64
os: darwin-arm64
bin: ${{ needs.release.outputs.bin-name }}
name: ${{ needs.release.outputs.pkg-name }}-RaspberryPi.tar.gz
command: build
name: ${{ needs.release.outputs.pkg-name }}-Darwin-x86_64.tar.gz

name: Upload asset for ${{ matrix.platform.release_for }}
runs-on: ${{ matrix.platform.os }}
Expand All @@ -162,22 +154,30 @@ jobs:
printf '*%.0s' {1..60} && printf "\n"
echo "Updated rust version: $(rustc --version)"
printf '*%.0s' {1..60} && printf "\n"
shell: bash

- name: Install OpenSSL static for Windows
# https://github.com/sfackler/rust-openssl/issues/1086
if: ${{ matrix.platform.os == 'windows-latest' }}
if: startsWith(matrix.platform.os, 'windows')
run: |
mkdir \Tools
if (-Not (Test-Path -Path \Tools)) {
mkdir \Tools
}
cd \Tools
git clone https://github.com/Microsoft/vcpkg.git
if (-Not (Test-Path -Path .\vcpkg)) {
git clone https://github.com/Microsoft/vcpkg.git
}
cd vcpkg
echo ("vcpkg_dir=" + $pwd) >> $env:GITHUB_ENV
.\bootstrap-vcpkg.bat
if (-Not (Test-Path -Path .\vcpkg.exe)) {
.\bootstrap-vcpkg.bat
}
.\vcpkg.exe install openssl:x64-windows-static
shell: pwsh

- name: Build
run: |
if [ "${{ matrix.platform.os }}" == "windows-latest" ]; then
if [[ "${{ matrix.platform.os }}" =~ ^windows ]]; then
echo "Setting vcpkg env vars for OpenSSL in Windows"
export OPENSSL_DIR="${{ env.vcpkg_dir }}\installed\x64-windows-static"
export OPENSSL_STATIC="Yes"
Expand All @@ -188,7 +188,7 @@ jobs:

- name: Run tests
run: |
if [ "${{ matrix.platform.os }}" == "windows-latest" ]; then
if [[ "${{ matrix.platform.os }}" =~ ^windows ]]; then
echo "Setting vcpkg env vars for OpenSSL in Windows"
export OPENSSL_DIR="${{ env.vcpkg_dir }}\installed\x64-windows-static"
export OPENSSL_STATIC="Yes"
Expand All @@ -197,19 +197,21 @@ jobs:
cargo test --no-run
shell: bash

- name: Copy Artifacts (Windows)
if: ${{ matrix.platform.os == 'windows-latest' }}
- name: Compress and Copy Artifact (Windows)
if: startsWith(matrix.platform.os, 'windows')
run: |
mkdir -p ${{ needs.release.outputs.pkg-name }}
cp target/release/${{ matrix.platform.bin }} ${{ needs.release.outputs.pkg-name }}/${{ matrix.platform.bin }}
Compress-Archive -DestinationPath ${{ matrix.platform.name }} -Path ${{ needs.release.outputs.pkg-name }}/
shell: pwsh

- name: Copy Artifacts (macOS/Ubuntu)
if: ${{ matrix.platform.os != 'windows-latest' }}
- name: Compress and Copy Artifact (macOS/Ubuntu)
if: "!startsWith(matrix.platform.os, 'windows')"
run: |
mkdir -p ${{ needs.release.outputs.pkg-name }}
cp target/release/${{ matrix.platform.bin }} ${{ needs.release.outputs.pkg-name }}/${{ matrix.platform.bin }}
tar -zcvf ${{ matrix.platform.name }} ${{ needs.release.outputs.pkg-name }}/
shell: bash

- name: Upload Asset to Release
run: |
Expand All @@ -222,7 +224,7 @@ jobs:
publish-crate:
needs: upload_assets
if: needs.release.outputs.release-flag == 'true'
runs-on: ubuntu-latest
runs-on: thevickypedia-lite
steps:
- uses: actions/checkout@v4
- name: Update Rust
Expand All @@ -234,6 +236,7 @@ jobs:
printf '*%.0s' {1..60} && printf "\n"
echo "Updated rust version: $(rustc --version)"
printf '*%.0s' {1..60} && printf "\n"
shell: bash
- name: Release Crate
run: |
cargo login ${{ secrets.CRATES_TOKEN }}
Expand Down
36 changes: 18 additions & 18 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "RuStream"
version = "1.3.0-a"
version = "1.3.0"
description = "Self-hosted Streaming Engine, that can render media files via authenticated sessions."
license = "MIT"
documentation = "https://docs.rs/RuStream"
Expand All @@ -26,26 +26,26 @@ path = "src/main.rs"
rustdoc-args = ["--document-private-items"]

[dependencies]
actix-rt = "2.9.0"
actix-web = { version = "4.5.1", features = ["openssl"] }
actix-files = "0.6.5"
actix-rt = "2.10.0"
actix-web = { version = "4.8.0", features = ["openssl"] }
actix-files = "0.6.6"
actix-cors = "0.7.0"
actix-multipart = "0.6.1"
serde = { version = "1.0.196", features = ["derive"] }
serde_json = "1.0.113"
chrono = { version = "0.4.33", features = ["serde"] }
env_logger = "0.11.1"
log = "0.4.20"
base64 = "0.22.0"
actix-multipart = "0.6.2"
serde = { version = "1.0.203", features = ["derive"] }
serde_json = "1.0.117"
chrono = { version = "0.4.38", features = ["serde"] }
env_logger = "0.11.3"
log = "0.4.21"
base64 = "0.22.1"
sha2 = "0.10.8"
rand = "0.8.5"
fernet = "0.2.1"
minijinja = { version = "1.0.12", features = ["loader"] }
url = "2.5.0"
regex = "1.5"
walkdir = "2.3.2"
openssl = "0.10"
fernet = "0.2.2"
minijinja = { version = "2.0.2", features = ["loader"] }
url = "2.5.2"
regex = "1.10.5"
walkdir = "2.5.0"
openssl = "0.10.64"
dotenv = "0.15.0"
futures-util = "0.3.30"
[target.'cfg(target_os = "linux")'.dependencies]
openssl = { version = "0.10", features = ["vendored"] }
openssl = { version = "0.10.64", features = ["vendored"] }
1 change: 1 addition & 0 deletions src/constant.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ pub static IMAGE_FORMATS: [&str; 7] = ["jpeg", "jpg", "png", "gif", "bmp", "svg"
pub static SECURE_INDEX: &str = "SECURE_INDEX";

/// Struct to store the cargo information gathered at compile time using the `env!` macro.
#[allow(dead_code)]
#[derive(Debug, Clone)]
pub struct MetaData {
pub crate_name: String,
Expand Down

0 comments on commit 9a3dc8c

Please sign in to comment.