### Setup and Run nzbhydra-2-github-issue-reminder Bot Source: https://github.com/theotherp/nzbhydra2/blob/master/other/githubbot/nzbhydra2-github-issue-reminder/README.md This snippet outlines the necessary steps to set up and run the GitHub App. It includes commands for installing project dependencies using npm, building the TypeScript code, and starting the bot application. ```sh # Install dependencies npm install # Run typescript npm run build # Run the bot npm start ``` -------------------------------- ### Install Bower Components Source: https://github.com/theotherp/nzbhydra2/wiki/Development-of-frontend-resources Installs the project's front-end dependencies managed by Bower, as defined in bower.json. ```Shell bower install ``` -------------------------------- ### Install Gulp CLI Source: https://github.com/theotherp/nzbhydra2/wiki/Development-of-frontend-resources Installs the Gulp command-line interface globally using npm. ```Shell npm install -g gulp-cli ``` -------------------------------- ### Install Bower Source: https://github.com/theotherp/nzbhydra2/wiki/Development-of-frontend-resources Installs Bower, a package manager for the web, globally using npm. ```Shell npm install -g bower ``` -------------------------------- ### Install Node Modules Source: https://github.com/theotherp/nzbhydra2/wiki/Development-of-frontend-resources Installs the project's Node.js dependencies as defined in package.json. ```Shell npm install ``` -------------------------------- ### Install NZB Hydra 2 as a systemd service on Ubuntu/LinuxMint Source: https://github.com/theotherp/nzbhydra2/wiki/Windows-service-and-Linux-start-scripts This snippet details the steps to install NZB Hydra 2 as a systemd service on Ubuntu/LinuxMint 20. It includes creating a system account, copying files, configuring the service unit, and managing the service lifecycle. ```Bash sudo adduser --system --no-create-home --group nzbhydra2 ``` ```Bash cd ~ wget https://github.com/theotherp/nzbhydra2/releases/download/v7.3.0/nzbhydra2-7.3.0-amd64-linux.zip (or latest version) unzip nzbhydra2-7.3.0-amd64-linux.zip -d nzbhydra2 sudo mkdir -p /opt/nzbhydra2 sudo cp -r nzbhydra2/* /opt/nzbhydra2/ ``` ```Bash sudo chown -R nzbhydra2:nzbhydra2 /opt/nzbhydra2/ ``` ```Bash vi systemd/nzbhydra2.service # Change the following to look like this: # User=nzbhydra2 # Group=nzbhydra2 # WorkingDirectory=/opt/nzbhydra2/ # ExecStart=python3 /opt/nzbhydra2/nzbhydra2wrapperPy3.py --nobrowser ``` ```Bash sudo cp systemd/nzbhydra2.service /lib/systemd/system/ ``` ```Bash sudo systemctl enable nzbhydra2 ``` ```Bash sudo systemctl start nzbhydra2 ``` ```Bash sudo systemctl status nzbhydra2 ``` ```Bash sudo systemctl stop nzbhydra2 ``` ```Bash sudo systemctl disable nzbhydra2 ``` -------------------------------- ### Windows Native Build Environment Setup Source: https://github.com/theotherp/nzbhydra2/blob/master/nativeNotes.md Sets up the Windows environment for building native executables. This involves running the vcvars64.bat script, setting the PATH to GraalVM, and configuring JAVA_HOME. ```batch Run vcvars64.bat Set path to graalvm Set java_home to graalvm Set env variable HYDRA_NATIVE_BUILD=true ``` -------------------------------- ### Install Java and Build NZBHydra Source: https://github.com/theotherp/nzbhydra2/blob/master/nativeNotes.md Installs Java Development Kit (version 22.3.r17-grl) using SDKMAN and then compiles the NZBHydra project, skipping tests and utilizing parallel compilation. It also sets an environment variable for native builds and compiles the core module with native support. ```bash curl -s "https://get.sdkman.io" | bash source "/root/.sdkman/bin/sdkman-init.sh" sdk install java 22.3.r17-grl mvn --batch-mode clean install -DskipTests -T 1C export HYDRA_NATIVE_BUILD=true mvn -pl org.nzbhydra:core -Pnative clean native:compile -DskipTests ``` -------------------------------- ### Run NZBHydra on Linux (Python Wrapper) Source: https://github.com/theotherp/nzbhydra2/wiki/Updating-from-4.x-to-5.x If the primary 'nzbhydra' executable fails to start on Linux, try running the Python wrapper script instead. This can sometimes resolve startup issues. ```Shell sh nzbhydra.sh ``` -------------------------------- ### Install Build Dependencies and Maven Source: https://github.com/theotherp/nzbhydra2/blob/master/nativeNotes.md Installs necessary packages for building, including zip, unzip, wget, curl, and FreeType. It also downloads, extracts, and configures Apache Maven 3.8.7 for use. ```bash apt update apt install -y zip unzip wget curl libfreetype6 libfreetype6-dev apt-get install build-essential wget https://dlcdn.apache.org/maven/maven-3.8.7/binaries/apache-maven-3.8.7-bin.tar.gz -P /tmp tar xf /tmp/apache-maven-*.tar.gz -C /opt ln -s /opt/apache-maven-3.8.7 /opt/maven export M2_HOME=/opt/maven export MAVEN_HOME=/opt/maven export PATH=${M2_HOME}/bin:${PATH} ``` -------------------------------- ### Install Dependencies with npm Source: https://github.com/theotherp/nzbhydra2/blob/master/other/githubbot/nzbhydra2-github-issue-reminder/CONTRIBUTING.md Installs the project's dependencies using npm. This is a prerequisite for running tests and making changes. ```shell npm install ``` -------------------------------- ### Run NZBHydra 2 on Windows Source: https://github.com/theotherp/nzbhydra2/blob/master/readme.md Instructions for running NZBHydra 2 on Windows, including options for a tray icon or a console window. It also advises against installing in Program Files directories. ```batch NZBHydra2.exe NZBHydra2 Console.exe ``` -------------------------------- ### Windows Non-Docker Installation Source: https://github.com/theotherp/nzbhydra2/blob/master/nativeNotes.md Instructions for installing NZBHydra2 on Windows without Docker. This involves downloading the executable, shutting down the existing instance, backing up the configuration, deleting the 'lib' folder, extracting the new files, and restarting. ```shell Download https://ufile.io/hc29ixbe for windows and https://ufile.io/ddge0a8f for Linux. Shut down your NZBHydra instance. Make a copy of the whole folder. In the original main folder delete the "lib" folder. Extract the contents of the downloaded ZIP into the main folder, overwriting old files. Start NZBHydra as usual. ``` -------------------------------- ### Linux Non-Docker Installation Source: https://github.com/theotherp/nzbhydra2/blob/master/nativeNotes.md Instructions for installing NZBHydra2 on Linux without Docker. This involves downloading the executable, shutting down the existing instance, backing up the configuration, deleting the 'lib' folder, extracting the new files, and restarting. It also mentions the potential need to install 'libfreetype6'. ```shell Download https://ufile.io/hc29ixbe for windows and https://ufile.io/ddge0a8f for Linux. Shut down your NZBHydra instance. Make a copy of the whole folder. In the original main folder delete the "lib" folder. Extract the contents of the downloaded ZIP into the main folder, overwriting old files. Start NZBHydra as usual. On Linux you may need to install `libfreetype6`. ``` -------------------------------- ### Example API Search URL Source: https://github.com/theotherp/nzbhydra2/wiki/Tutorial-(Indexers,-newznab,-API,-*arr,-etc.) Demonstrates a typical URL structure for querying an indexer's API to search for content. It includes parameters for the API key, search type, and the search query itself. ```URL https://www.indexer.com/api?apikey=someapikey&t=search&q=whatever ``` -------------------------------- ### NZB Hydra 2 API Search Example Source: https://github.com/theotherp/nzbhydra2/wiki/External-API,-RSS-and-cached-queries This example demonstrates how to query the NZB Hydra 2 API for TV show releases with caching enabled. It specifies the API key, search type, and a cache time of 60 minutes. ```HTTP http://127.0.0.1:5076/api?apikey=myapikey&t=tvsearch&cachetime=60 ``` -------------------------------- ### NZB Hydra 2 API Stats Request Example Source: https://github.com/theotherp/nzbhydra2/wiki/External-API,-RSS-and-cached-queries This JSON object represents an example request to the `/api/stats` endpoint of NZB Hydra 2. It includes various parameters to retrieve detailed statistics about indexer performance, download history, and search patterns. ```JSON { "after": "2018-11-28T09:20:50.190Z", "before": "2018-12-29T09:20:50.190Z", "includeDisabled": true, "indexerApiAccessStats": true, "avgIndexerSearchResultsShares": true, "avgResponseTimes": true, "indexerDownloadShares": true, "downloadsPerDayOfWeek": true, "downloadsPerHourOfDay": true, "searchesPerDayOfWeek": true, "searchesPerHourOfDay": true, "downloadsPerAgeStats": true, "successfulDownloadsPerIndexer": true, "downloadSharesPerUser": false, "searchSharesPerUser": false, "downloadSharesPerIp": true, "searchSharesPerIp": true, "userAgentSearchShares": true, "userAgentDownloadShares": true } ``` -------------------------------- ### Update NZBHydra 2 (x64) Source: https://github.com/theotherp/nzbhydra2/wiki/Updating-from-4.x-to-5.x Instructions for updating NZBHydra 2 on x64 systems. This involves deleting the 'lib' folder, downloading the latest release zip, and extracting it to overwrite existing files. ```Shell rm -rf lib # Download and extract the latest release zip for x64 ``` -------------------------------- ### Search Results Table Source: https://github.com/theotherp/nzbhydra2/blob/master/core/src/test/resources/org/nzbhydra/mapping/binsearch_singlepage.html This snippet displays the search results in a table format. It includes columns for an index, a checkbox, the subject of the result, and the age. A 'Create NZB' button is also present, which submits a GET request to '/nzb' with the search query. ```html
``` -------------------------------- ### Update NZBHydra 2 (Generic Release) Source: https://github.com/theotherp/nzbhydra2/wiki/Updating-from-4.x-to-5.x Instructions for updating NZBHydra 2 using the generic release, which is required for architectures or OSes other than standard x64 Linux/Windows, or if the native executable fails. This method still requires Java 17. ```Shell # Download and extract the 'generic' release zip ``` -------------------------------- ### Sonarr Query Example for NZBHydra Source: https://github.com/theotherp/nzbhydra2/wiki/Tutorial-(Indexers,-newznab,-API,-*arr,-etc.) Demonstrates how Sonarr queries NZBHydra for specific TV show episodes using a structured format that includes the search type and TVDB ID. ```URL Parameters t=tvshow&tvdbid=73739&season=1&episode=12 ``` -------------------------------- ### NZBHydra2 Basic Text Search Source: https://github.com/theotherp/nzbhydra2/wiki/Tutorial-(Indexers,-newznab,-API,-*arr,-etc.) Illustrates the basic 'search' type in NZBHydra2 using the 'q' parameter for text-based queries. It also shows an 'update query' example without a specific search term. ```URL t=search&q=whatever ``` ```URL t=search&cat=2000 ``` -------------------------------- ### Docker Deployment Instructions Source: https://github.com/theotherp/nzbhydra2/blob/master/nativeNotes.md Provides instructions for deploying NZBHydra2 using Docker. It involves creating a copy of the configuration folder and running the specified Docker image, mounting the data volume. ```shell Make a copy of your config folder. Run `docker.io/thespad/playground:nzbhydra2` mounting the copy of the data folder (see https://github.com/linuxserver/docker-nzbhydra2 for details). You can choose to shut down your other instance and map the original port or use this instance in parallel, mapping another port (e.g. 5062:5061). ``` -------------------------------- ### Linux Docker Deployment Instructions Source: https://github.com/theotherp/nzbhydra2/blob/master/nativeNotes.md Provides instructions for deploying NZBHydra2 using Docker on Linux. It involves creating a copy of the configuration folder and running the specified Docker image, mounting the data volume. ```shell Make a copy of your config folder. Run `docker.io/thespad/playground:nzbhydra2` mounting the copy of the data folder (see https://github.com/linuxserver/docker-nzbhydra2 for details). You can choose to shut down your other instance and map the original port or use this instance in parallel, mapping another port (e.g. 5062:5061). ``` -------------------------------- ### NZBHydra 2 Docker Images Source: https://github.com/theotherp/nzbhydra2/blob/master/readme.md Lists available Docker images for NZBHydra 2 from different providers, including hotio, binhex, and LinuxServer.io. ```docker docker pull hotio/nzbhydra2 docker pull binhex/arch-nzbhydra2 docker pull linuxserver/nzbhydra2 ``` -------------------------------- ### SOCKS5 Server SSL Anonymous in Java Source: https://github.com/theotherp/nzbhydra2/blob/master/other/sockslib/README.md Configures and starts an anonymous SOCKS5 proxy server with SSL enabled using SocksLib. This involves setting up SSL properties, including the keystore path, password, and client authentication settings, before starting the server on a specified port. ```Java SSLConfigurationBuilder builder = SSLConfigurationBuilder.newBuilder(); builder.setKeyStorePath("server-keystore.jks"); builder.setKeyStorePassword("123456"); builder.setClientAuth(false); socksProxyServer = SocksServerBuilder.buildAnonymousSSLSocks5Server(1081, builder.build()); socksProxyServer.start(); ``` -------------------------------- ### Run NZBHydra 2 with Java Source: https://github.com/theotherp/nzbhydra2/blob/master/readme.md Instructions for running NZBHydra 2 on any OS or architecture using Java 17. It requires the Java executable to be in the PATH or specified via a parameter. ```shell --java