diff --git a/CloudronManifest.json b/CloudronManifest.json new file mode 100644 index 0000000..246fe80 --- /dev/null +++ b/CloudronManifest.json @@ -0,0 +1,20 @@ +{ + "id": "whisparr.com", + "title": "Whisparr", + "author": "Jean-Benoît RICHEZ ", + "description": "Whisparr is an adult movie collection manager for Usenet and BitTorrent users", + "tagline": "A great beginning", + "version": "0.0.1", + "healthCheckPath": "/", + "httpPort": 6969, + "addons": { + "localstorage": {} + }, + "manifestVersion": 2, + "website": "https://whisparr.com", + "contactEmail": "support@cloudron.io", + "icon": "file://icon.png", + "tags": [ "media", "movies", "adult" ], + "mediaLinks": [ "https://whisparr.com" ] + } + diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..ff7d752 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,83 @@ +# Stage 1: Extract Whisparr binaries from available Docker image +# Default to linux/amd64 for Cloudron compatibility, but allow override +ARG TARGETPLATFORM=linux/amd64 +ARG BUILDPLATFORM +# Explicitly use linux/amd64 to ensure correct architecture +FROM --platform=linux/amd64 thespad/whisparr:latest AS whisparr-source + +# Stage 2: Build the Cloudron image +# Use explicit amd64 to match the source image +FROM --platform=linux/amd64 cloudron/base:4.2.0@sha256:46da2fffb36353ef714f97ae8e962bd2c212ca091108d768ba473078319a47f4 + +RUN apt-get update -y && \ + apt install -y curl sqlite3 dpkg file libstdc++6 libgcc-s1 libicu-dev + +RUN mkdir -p /app/code/whisparr +WORKDIR /app/code + +# Copy Whisparr binaries from the source image +# Most Whisparr Docker images have the binary in /app/whisparr +COPY --from=whisparr-source /app/whisparr /app/code/whisparr + +# Copy musl libc dynamic linker from the source image +# Whisparr binary uses musl libc which is not in the Cloudron base image (which uses glibc) +RUN mkdir -p /lib /usr/lib +COPY --from=whisparr-source /lib/ld-musl-x86_64.so.1 /lib/ld-musl-x86_64.so.1 +# Create the symlink for libc.musl (it's a symlink to ld-musl in the source) +RUN ln -sf /lib/ld-musl-x86_64.so.1 /lib/libc.musl-x86_64.so.1 + +# Copy musl-compatible C++ standard library and GCC support library from source image +# These are musl-linked versions needed by the Whisparr binary +COPY --from=whisparr-source /usr/lib/libstdc++.so.6.0.33 /usr/lib/libstdc++.so.6.0.33 +COPY --from=whisparr-source /usr/lib/libgcc_s.so.1 /usr/lib/libgcc_s.so.1 +# Create symlinks if needed +RUN if [ ! -f /usr/lib/libstdc++.so.6 ]; then \ + ln -sf /usr/lib/libstdc++.so.6.0.33 /usr/lib/libstdc++.so.6; \ + fi + +# Copy ICU libraries from source image (required by .NET applications) +COPY --from=whisparr-source /usr/lib/libicudata.so.76.1 /usr/lib/libicudata.so.76.1 +COPY --from=whisparr-source /usr/lib/libicui18n.so.76.1 /usr/lib/libicui18n.so.76.1 +COPY --from=whisparr-source /usr/lib/libicuio.so.76.1 /usr/lib/libicuio.so.76.1 +COPY --from=whisparr-source /usr/lib/libicuuc.so.76.1 /usr/lib/libicuuc.so.76.1 +COPY --from=whisparr-source /usr/share/icu /usr/share/icu +# Create symlinks for ICU libraries +RUN ln -sf /usr/lib/libicudata.so.76.1 /usr/lib/libicudata.so.76 && \ + ln -sf /usr/lib/libicui18n.so.76.1 /usr/lib/libicui18n.so.76 && \ + ln -sf /usr/lib/libicuio.so.76.1 /usr/lib/libicuio.so.76 && \ + ln -sf /usr/lib/libicuuc.so.76.1 /usr/lib/libicuuc.so.76 + +# Copy OpenSSL libraries from source image (required by .NET applications for HTTPS/TLS) +COPY --from=whisparr-source /usr/lib/libssl.so.3 /usr/lib/libssl.so.3 +COPY --from=whisparr-source /usr/lib/libcrypto.so.3 /usr/lib/libcrypto.so.3 + +# Copy SQLite library from source image (required for database operations) +COPY --from=whisparr-source /usr/lib/libsqlite3.so.3.49.2 /usr/lib/libsqlite3.so.3.49.2 +RUN ln -sf /usr/lib/libsqlite3.so.3.49.2 /usr/lib/libsqlite3.so.0 + +# Copy Brotli compression libraries from source image (required for HTTP compression) +COPY --from=whisparr-source /usr/lib/libbrotlicommon.so.1.1.0 /usr/lib/libbrotlicommon.so.1.1.0 +COPY --from=whisparr-source /usr/lib/libbrotlidec.so.1.1.0 /usr/lib/libbrotlidec.so.1.1.0 +COPY --from=whisparr-source /usr/lib/libbrotlienc.so.1.1.0 /usr/lib/libbrotlienc.so.1.1.0 +RUN ln -sf /usr/lib/libbrotlicommon.so.1.1.0 /usr/lib/libbrotlicommon.so.1 && \ + ln -sf /usr/lib/libbrotlidec.so.1.1.0 /usr/lib/libbrotlidec.so.1 && \ + ln -sf /usr/lib/libbrotlienc.so.1.1.0 /usr/lib/libbrotlienc.so.1 + +# Copy zlib library from source image (required by libSystem.IO.Compression.Native) +COPY --from=whisparr-source /usr/lib/libz.so.1.3.1 /usr/lib/libz.so.1.3.1 +RUN ln -sf /usr/lib/libz.so.1.3.1 /usr/lib/libz.so.1 + +# Verify the binary exists and set permissions +RUN if [ -f /app/code/whisparr/bin/Whisparr ]; then \ + file /app/code/whisparr/bin/Whisparr || echo "file command not available"; \ + chmod +x /app/code/whisparr/bin/Whisparr; \ + fi && \ + chmod +x /lib/ld-musl-x86_64.so.1 && \ + chmod +x /lib/libc.musl-x86_64.so.1 && \ + chmod +x /app/code/whisparr/bin/libSystem.IO.Compression.Native.so 2>/dev/null || true + +COPY start.sh /app/code/ +RUN chown -R cloudron:cloudron /app/code/whisparr && \ + chmod +x /app/code/whisparr/bin/Whisparr 2>/dev/null || true + +CMD [ "/app/code/start.sh" ] diff --git a/LICENSE b/LICENSE deleted file mode 100644 index b083747..0000000 --- a/LICENSE +++ /dev/null @@ -1,18 +0,0 @@ -MIT License - -Copyright (c) 2026 bradinfluence - -Permission is hereby granted, free of charge, to any person obtaining a copy of this software and -associated documentation files (the "Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the -following conditions: - -The above copyright notice and this permission notice shall be included in all copies or substantial -portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT -LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO -EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER -IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE -USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/README.md b/README.md index 57469cb..e13228e 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,71 @@ -# cloudron-whisparr +# Whisparr Cloudron App + +Whisparr is an adult movie collection manager for Usenet and BitTorrent users, similar to Radarr but for adult content. + +## Installation + +### Prerequisites + +You need to install Cloudron CLI: [here](https://docs.cloudron.io/cli/). After you need to connect the CLI to your cloudron instance. + +### Install app + +To install Whisparr, navigate to this directory and run: + +```bash +cloudron install --image [DOCKER IMAGE NAME] +``` + +**Important:** Always install the application with the greatest version image. For example, if `jbrichez/cloudron-whisparr` greatest is `0.5`, install `jbrichez/cloudron-whisparr:0.5` with cloudron cli. If not, cloudron CLI will install the `latest` version which is not valid. Why? Because cloudron internal registry needs a tagged image version other from `latest` to be able to update version when new image is out. + +### Cloudron volumes + +You will need to create: + +* (1) volume as **download folder** for your download client +* (2) volume as **your movies library** for Whisparr + +Here is the guide to create cloudron volume: [guide](https://docs.cloudron.io/apps/storage/). + +**I recommend to choose "Filesystem" mount type when you create the volumes.** +**⚠️ You need to physically create the folder on host before, cloudron can't create one for you.** + +To connect a volume to a specific app, go to app's settings, then "storage" tab and "mount" options on right panel. + +You will need to: + +* connect (1) and (2) to Whisparr's App. +* connect (1) to your download client app (e.g., nzbget, sabnzbd). + +You can mount volumes to app in the app's settings and "storage" tab. + +### Docker network + +You will need to have the internal IP of your container when you will connect services together. To get private IP you need to connect to your VPS. + +Get your container's name: + +```bash +docker ps -a +``` + +Find the cloudron network's name (sometimes: cloudron): + +```bash +docker network ls +``` + +List ip of all containers connected to network: + +```bash +docker network inspect cloudron +``` + +## About + +Whisparr is a fork of Radarr for managing adult movie collections. It works with Usenet and BitTorrent download clients. + +## License + +MIT license -Whisparr adult movie collection manager. Packaged for Cloudron. \ No newline at end of file diff --git a/icon.png b/icon.png new file mode 100644 index 0000000..70a3b58 Binary files /dev/null and b/icon.png differ diff --git a/start.sh b/start.sh new file mode 100755 index 0000000..cb04b7d --- /dev/null +++ b/start.sh @@ -0,0 +1,32 @@ +#!/bin/sh + +set -eu + +echo "Starting Whisparr..." + +# Find the Whisparr binary (it might be in different locations) +WHISPARR_BIN="" + +if [ -f /app/code/whisparr/bin/Whisparr ]; then + WHISPARR_BIN="/app/code/whisparr/bin/Whisparr" +elif [ -f /app/code/whisparr/Whisparr/Whisparr ]; then + WHISPARR_BIN="/app/code/whisparr/Whisparr/Whisparr" +elif [ -f /app/code/whisparr/Whisparr ]; then + WHISPARR_BIN="/app/code/whisparr/Whisparr" +else + # Try to find it + WHISPARR_BIN=$(find /app/code/whisparr -name "Whisparr" -type f | head -1) +fi + +if [ -z "$WHISPARR_BIN" ] || [ ! -f "$WHISPARR_BIN" ]; then + echo "Error: Could not find Whisparr binary" + echo "Searched in: /app/code/whisparr" + find /app/code/whisparr -type f | head -10 + exit 1 +fi + +# Ensure it's executable +chmod +x "$WHISPARR_BIN" 2>/dev/null || true + +echo "Found Whisparr at: $WHISPARR_BIN" +exec "$WHISPARR_BIN" -nobrowser -data=/app/data/config/