v1.0.9: GitHub Releases APK deployment + new Android icons
This commit is contained in:
parent
3341f20256
commit
893fe088a3
5 changed files with 122 additions and 36 deletions
16
README.md
16
README.md
|
|
@ -2,18 +2,18 @@
|
|||
|
||||
[](https://hub.docker.com/r/vndangkhoa/streamflix)
|
||||
[](https://github.com/vndangkhoa/Streamflow)
|
||||
[](https://github.com/vndangkhoa/Streamflow/releases)
|
||||
[](https://github.com/vndangkhoa/Streamflow/releases)
|
||||
|
||||
StreamFlow is a high-fidelity movie streaming application designed for NAS enthusiasts and home cinema lovers. It combines a premium **Apple TV+ inspired aesthetic** with a lightweight, high-performance backend, now consolidated into a **single Docker image** for effortless deployment.
|
||||
|
||||
## 📋 Latest Release: v1.0.8
|
||||
## 📋 Latest Release: v1.0.9
|
||||
|
||||
**What's New in v1.0.8:**
|
||||
- 📱 **Android Live Updates:** App now loads content directly from server (no need to reinstall APK for UI updates)
|
||||
- 🤖 **Auto-Update Script:** Added `deploy_apk.sh` for one-click deployment
|
||||
- 🛠️ **Docker Optimization:** Simplified build process (unified backend/frontend)
|
||||
**What's New in v1.0.9:**
|
||||
- 📱 **GitHub Releases APK:** Android APK now hosted on GitHub Releases (no Docker rebuild needed)
|
||||
- 🎨 **New App Icon:** Updated Android launcher icon with StreamFlix branding
|
||||
- <EFBFBD> **Simplified Deployment:** `deploy_apk.sh` now uploads directly to GitHub Releases
|
||||
|
||||
**Previous (v1.0.7):**
|
||||
**Previous (v1.0.8):**
|
||||
- 🔧 **HOTFIX: Fixed Docker crash** - Added missing `Request` import causing NameError on startup
|
||||
|
||||
**Previous (v1.0.6):**
|
||||
|
|
@ -68,7 +68,7 @@ version: '3.8'
|
|||
services:
|
||||
# StreamFlow Unified (Backend + Frontend)
|
||||
app:
|
||||
image: vndangkhoa/streamflix:1.0.8
|
||||
image: vndangkhoa/streamflix:1.0.9
|
||||
platform: linux/amd64
|
||||
ports:
|
||||
- "3478:8000"
|
||||
|
|
|
|||
|
|
@ -215,8 +215,9 @@
|
|||
<div class="platform-card">
|
||||
<span class="platform-icon">🤖</span>
|
||||
<h2 class="platform-title">Android Mobile & TV</h2>
|
||||
<span class="platform-version">Version 1.0.6 (Universal APK)</span>
|
||||
<a href="/StreamFlix-Universal-v1.0.8.apk" class="btn-download" download>Download APK</a>
|
||||
<span class="platform-version">Latest Version (Universal APK)</span>
|
||||
<a href="https://github.com/vndangkhoa/Streamflow/releases/latest/download/StreamFlix.apk"
|
||||
class="btn-download" target="_blank">Download APK</a>
|
||||
|
||||
<div class="instructions">
|
||||
<strong>How to install:</strong>
|
||||
|
|
@ -250,7 +251,7 @@
|
|||
</div>
|
||||
|
||||
<p style="color: #666; font-size: 0.8rem; margin-top: 40px;">
|
||||
StreamFlix v1.0.8 (Gold Master) • Private Access Only
|
||||
StreamFlix • Private Access Only
|
||||
</p>
|
||||
</div>
|
||||
|
||||
|
|
|
|||
71
deploy_apk.sh
Normal file → Executable file
71
deploy_apk.sh
Normal file → Executable file
|
|
@ -1,38 +1,65 @@
|
|||
#!/bin/bash
|
||||
APK_SOURCE="frontend/android/app/build/outputs/apk/debug/app-debug.apk"
|
||||
APK_DEST="backend/static/StreamFlix-Universal-v1.0.8.apk"
|
||||
HTML_FILE="backend/static/download.html"
|
||||
# StreamFlix APK Deployment Script
|
||||
# Uploads APK to GitHub Releases for easy distribution
|
||||
|
||||
echo "🚀 Deploying Android APK v1.0.8..."
|
||||
APK_SOURCE="frontend/android/app/build/outputs/apk/debug/app-debug.apk"
|
||||
REPO="vndangkhoa/Streamflow"
|
||||
|
||||
# Get version from build.gradle
|
||||
VERSION=$(grep -o 'versionName "[^"]*"' frontend/android/app/build.gradle | sed 's/versionName "//;s/"//')
|
||||
TAG="v${VERSION}"
|
||||
|
||||
echo "🚀 Deploying StreamFlix APK ${TAG}..."
|
||||
|
||||
# 1. Check if APK exists
|
||||
if [ ! -f "$APK_SOURCE" ]; then
|
||||
echo "❌ APK build not found at $APK_SOURCE"
|
||||
echo " Please wait for the build to finish."
|
||||
echo " Run ./build_apk.sh first to build the APK."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# 2. Move and Rename APK
|
||||
echo "📦 Moving APK to static folder..."
|
||||
cp "$APK_SOURCE" "$APK_DEST"
|
||||
# Remove old APK if exists
|
||||
rm -f "backend/static/StreamFlix-Universal-v1.0.6.apk"
|
||||
# 2. Check if gh CLI is installed
|
||||
if ! command -v gh &> /dev/null; then
|
||||
echo "❌ GitHub CLI (gh) is not installed."
|
||||
echo " Install it with: brew install gh"
|
||||
echo " Then authenticate with: gh auth login"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# 3. Update Download Page
|
||||
echo "📝 Updating download.html..."
|
||||
# Use perl for cross-platform regex replacement (handles Mac/Linux nuances better than sed)
|
||||
perl -i -pe 's/v1\.0\.6/v1.0.8/g' "$HTML_FILE"
|
||||
# 3. Copy APK with standard name
|
||||
APK_NAME="StreamFlix.apk"
|
||||
cp "$APK_SOURCE" "$APK_NAME"
|
||||
echo "📦 Prepared APK: $APK_NAME"
|
||||
|
||||
# 4. Git Commit & Push
|
||||
echo "octocat: Committing to GitHub..."
|
||||
git add "$APK_DEST" "$HTML_FILE"
|
||||
git commit -m "v1.0.8: Added Android APK to static assets"
|
||||
git push origin main
|
||||
# 4. Create GitHub Release and upload APK
|
||||
echo "📤 Creating GitHub Release ${TAG}..."
|
||||
|
||||
# Check if release already exists
|
||||
if gh release view "$TAG" --repo "$REPO" &> /dev/null; then
|
||||
echo "⚠️ Release $TAG already exists. Updating..."
|
||||
gh release upload "$TAG" "$APK_NAME" --repo "$REPO" --clobber
|
||||
else
|
||||
echo "✨ Creating new release $TAG..."
|
||||
gh release create "$TAG" "$APK_NAME" \
|
||||
--repo "$REPO" \
|
||||
--title "StreamFlix ${TAG}" \
|
||||
--notes "### What's New in ${TAG}
|
||||
- 🤖 Android APK Release
|
||||
- 📱 Universal APK for all Android devices
|
||||
|
||||
### Download
|
||||
Click **StreamFlix.apk** below to download."
|
||||
fi
|
||||
|
||||
# 5. Cleanup
|
||||
rm "$APK_NAME"
|
||||
|
||||
echo ""
|
||||
echo "✅ DEPLOYMENT SUCCESSFUL!"
|
||||
echo "------------------------------------------------"
|
||||
echo "👉 Next Step: Update your NAS Docker container."
|
||||
echo " docker pull vndangkhoa/streamflix:1.0.8"
|
||||
echo " (or rebuild if you are building locally)"
|
||||
echo "📱 Download URL:"
|
||||
echo " https://github.com/${REPO}/releases/latest/download/StreamFlix.apk"
|
||||
echo ""
|
||||
echo "🌐 The download page will automatically link to this APK."
|
||||
echo " No Docker rebuild required!"
|
||||
echo "------------------------------------------------"
|
||||
|
|
|
|||
|
|
@ -215,8 +215,9 @@
|
|||
<div class="platform-card">
|
||||
<span class="platform-icon">🤖</span>
|
||||
<h2 class="platform-title">Android Mobile & TV</h2>
|
||||
<span class="platform-version">Version 1.0.6 (Universal APK)</span>
|
||||
<a href="/StreamFlix-Universal-v1.0.6.apk" class="btn-download" download>Download APK</a>
|
||||
<span class="platform-version">Latest Version (Universal APK)</span>
|
||||
<a href="https://github.com/vndangkhoa/Streamflow/releases/latest/download/StreamFlix.apk"
|
||||
class="btn-download" target="_blank">Download APK</a>
|
||||
|
||||
<div class="instructions">
|
||||
<strong>How to install:</strong>
|
||||
|
|
@ -250,7 +251,7 @@
|
|||
</div>
|
||||
|
||||
<p style="color: #666; font-size: 0.8rem; margin-top: 40px;">
|
||||
StreamFlix v1.0.6 (Gold Master) • Private Access Only
|
||||
StreamFlix • Private Access Only
|
||||
</p>
|
||||
</div>
|
||||
|
||||
|
|
|
|||
57
generate_android_icons.sh
Executable file
57
generate_android_icons.sh
Executable file
|
|
@ -0,0 +1,57 @@
|
|||
#!/bin/bash
|
||||
# Generate Android App Icons from source image
|
||||
# Usage: ./generate_android_icons.sh <source_image.png>
|
||||
|
||||
SOURCE_IMAGE="${1:-streamflix_icon.png}"
|
||||
RES_DIR="frontend/android/app/src/main/res"
|
||||
|
||||
if [ ! -f "$SOURCE_IMAGE" ]; then
|
||||
echo "❌ Source image not found: $SOURCE_IMAGE"
|
||||
echo " Usage: ./generate_android_icons.sh <source_image.png>"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "🎨 Generating Android launcher icons from: $SOURCE_IMAGE"
|
||||
|
||||
resize_image() {
|
||||
local input=$1
|
||||
local output=$2
|
||||
local size=$3
|
||||
|
||||
if command -v convert &> /dev/null; then
|
||||
convert "$input" -resize "${size}x${size}" "$output"
|
||||
elif command -v sips &> /dev/null; then
|
||||
cp "$input" "$output"
|
||||
sips -z "$size" "$size" "$output" > /dev/null 2>&1
|
||||
else
|
||||
echo "❌ Neither ImageMagick (convert) nor sips is available."
|
||||
exit 1
|
||||
fi
|
||||
}
|
||||
|
||||
# Generate icons for each density
|
||||
generate_icons() {
|
||||
local density=$1
|
||||
local size=$2
|
||||
local fg_size=$3
|
||||
local dir="$RES_DIR/mipmap-$density"
|
||||
|
||||
mkdir -p "$dir"
|
||||
|
||||
echo " 📱 $density: ${size}x${size}px (foreground: ${fg_size}x${fg_size}px)"
|
||||
|
||||
resize_image "$SOURCE_IMAGE" "$dir/ic_launcher.png" "$size"
|
||||
resize_image "$SOURCE_IMAGE" "$dir/ic_launcher_round.png" "$size"
|
||||
resize_image "$SOURCE_IMAGE" "$dir/ic_launcher_foreground.png" "$fg_size"
|
||||
}
|
||||
|
||||
# Android density -> icon size -> foreground size
|
||||
generate_icons "mdpi" 48 108
|
||||
generate_icons "hdpi" 72 162
|
||||
generate_icons "xhdpi" 96 216
|
||||
generate_icons "xxhdpi" 144 324
|
||||
generate_icons "xxxhdpi" 192 432
|
||||
|
||||
echo ""
|
||||
echo "✅ Icons generated successfully!"
|
||||
echo " Now rebuild the APK with: ./build_apk.sh"
|
||||
Loading…
Reference in a new issue