├── .gitignore ├── LICENSE ├── README.md ├── apps ├── _appsgen.sh ├── _core.yml ├── _cron.list ├── _cron.yml ├── _downloaders.yml ├── _plugins.yml ├── crontabs │ └── nzbget_cron.yml ├── emby.yml ├── image │ ├── .old#p#lex │ ├── _image.sh │ ├── netdata │ ├── nzbget │ ├── ombi │ ├── plex │ ├── radarr │ ├── radarr4k │ ├── radarrhdr │ ├── rutorrent │ ├── sabnzbd │ ├── sonarr │ ├── sonarr4k │ ├── sonarrhdr │ └── tautulli ├── jackett.yml ├── jdownloader2.yml ├── jellyfin.yml ├── lazylibrarian.yml ├── lidarr.yml ├── netdata.yml ├── nzbget.yml ├── nzbhydra.yml ├── ombi.yml ├── ombi4k.yml ├── ombiHDR.yml ├── overseer.yml ├── pgui.yml ├── plex.yml ├── portainer.yml ├── qbittorrent.yml ├── radarr.yml ├── radarr4k.yml ├── radarrhdr.yml ├── rutorrent.yml ├── sabnzbd.yml ├── sonarr.yml ├── sonarr4k.yml ├── sonarrhdr.yml ├── tautulli.yml └── templates │ ├── nzbget │ ├── mp4_automator │ │ └── autoProcess.ini │ ├── scripts.yml │ └── scripts │ │ ├── DeleteSamples.py │ │ ├── FakeDetector.py │ │ ├── flatten.py │ │ ├── hash.py │ │ ├── rarfile │ │ ├── __init__.py │ │ └── rarfile.py │ │ ├── reverse_name.py │ │ └── unzip.py │ ├── radarr │ ├── mp4_automator │ │ └── autoProcess.ini │ ├── radarr.ini │ └── scripts │ │ └── cleanup-radarr.sh │ ├── radarr4k │ ├── mp4_automator │ │ └── autoProcess.ini │ └── scripts │ │ └── cleanup-radarr.sh │ ├── radarrhdr │ ├── mp4_automator │ │ └── autoProcess.ini │ └── scripts │ │ └── cleanup-radarr.sh │ ├── rutorrent │ ├── plugins │ │ └── mobile │ │ │ ├── LICENSE │ │ │ ├── README.md │ │ │ ├── css │ │ │ ├── bootstrap.min.css │ │ │ └── bootstrap.min.css.map │ │ │ ├── fonts │ │ │ ├── glyphicons-halflings-regular.eot │ │ │ ├── glyphicons-halflings-regular.svg │ │ │ ├── glyphicons-halflings-regular.ttf │ │ │ ├── glyphicons-halflings-regular.woff │ │ │ └── glyphicons-halflings-regular.woff2 │ │ │ ├── init.js │ │ │ ├── js │ │ │ └── bootstrap.min.js │ │ │ ├── lang │ │ │ ├── cs.js │ │ │ ├── da.js │ │ │ ├── de.js │ │ │ ├── el.js │ │ │ ├── en.js │ │ │ ├── es.js │ │ │ ├── fi.js │ │ │ ├── fr.js │ │ │ ├── hu.js │ │ │ ├── it.js │ │ │ ├── lv.js │ │ │ ├── nl.js │ │ │ ├── pl.js │ │ │ ├── pt.js │ │ │ ├── ru.js │ │ │ ├── sk.js │ │ │ ├── sr.js │ │ │ ├── sv.js │ │ │ ├── tr.js │ │ │ ├── uk.js │ │ │ ├── vi.js │ │ │ ├── zh-cn.js │ │ │ └── zh-tw.js │ │ │ ├── mobile.css │ │ │ ├── mobile.html │ │ │ └── plugin.info │ ├── rutorrent │ │ └── settings │ │ │ ├── config.php │ │ │ └── plugins.ini │ └── tasks │ │ ├── dynamic.yml │ │ └── main.yml │ ├── sonarr │ ├── mp4_automator │ │ └── autoProcess.ini │ └── sonarr.ini │ ├── sonarr4k │ └── mp4_automator │ │ └── autoProcess.ini │ ├── sonarrhdr │ └── mp4_automator │ │ └── autoProcess.ini │ └── tasks │ └── dynamic.yml └── place.holder /.gitignore: -------------------------------------------------------------------------------- 1 | 2 | .DS_Store 3 | apps/rclonegui.yml 4 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | ##### WANT TO HELP? CLICK THE ★ (STAR LOGO) in the Upper-Right! 2 |

3 | 4 | 5 | 6 | 7 |

8 | 9 | * 📂 [**[Click Here]**](https://goo.gl/7NR3Da) - Google G-Suite (Unlimited Hard Drive Space & Storage) 10 | * 📂 [**[Click Here]**](https://controlpanel.newshosting.com/signup/index.php?promo=partners&a_aid=5a65169240efd&a_bid=5ecfe99b) - Top Performance NewsHost! - Blitz Members Receive a 58% Discount 11 | ---- 12 | ### **Reference Shortcut -** http://wiki.pgblitz.com 13 | ---- 14 | 15 | ## 1. PG YouTube 16 | 17 |

18 |

PGBlitz Introduction Video

19 | 20 |

21 |

PGBlitz Installation Video

22 | 23 | [**[Click Here]**](https://pgblitz.com/threads/plexguide-install-instructions.243/) for installation instructions to start the process 24 | -------------------------------------------------------------------------------- /apps/_appsgen.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Author(s): Admin9705 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | 9 | # Generates App List 10 | ls -la /opt/coreapps/apps/ | sed -e 's/.yml//g' | 11 | awk '{print $9}' | tail -n +4 >/var/plexguide/app.list 12 | 13 | ls -la /opt/mycontainers/ | sed -e 's/.yml//g' | 14 | awk '{print $9}' | tail -n +4 >>/var/plexguide/app.list 15 | # Enter Items Here to Prevent them From Showing Up on AppList 16 | sed -i -e "/traefik/d" /var/plexguide/app.list 17 | sed -i -e "/image*/d" /var/plexguide/app.list 18 | sed -i -e "/_appsgen.sh/d" /var/plexguide/app.list 19 | sed -i -e "/_c*/d" /var/plexguide/app.list 20 | sed -i -e "/_a*/d" /var/plexguide/app.list 21 | sed -i -e "/_t*/d" /var/plexguide/app.list 22 | sed -i -e "/templates/d" /var/plexguide/app.list 23 | sed -i -e "/retry/d" /var/plexguide/app.list 24 | sed -i "/^test\b/Id" /var/plexguide/app.list 25 | sed -i -e "/nzbthrottle/d" /var/plexguide/app.list 26 | sed -i -e "/watchtower/d" /var/plexguide/app.list 27 | sed -i "/^_templates.yml\b/Id" /var/plexguide/app.list 28 | sed -i -e "/oauth/d" /var/plexguide/app.list 29 | sed -i -e "/dockergc/d" /var/plexguide/app.list 30 | sed -i -e "/crontabs/d" /var/plexguide/app.list 31 | sed -i -e "/archive/d" /var/plexguide/app.list 32 | -------------------------------------------------------------------------------- /apps/_core.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Author(s): Admin9705 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | # RECALL KEY VARIABLES ######################################################### 10 | 11 | - name: 'Register TLD' 12 | shell: 'cat /var/plexguide/tld.program' 13 | register: toplevel 14 | ignore_errors: True 15 | 16 | - name: Register Domain 17 | shell: 'cat /var/plexguide/server.domain' 18 | register: domain 19 | ignore_errors: True 20 | 21 | - name: Register IP 22 | shell: 'cat /var/plexguide/server.ip' 23 | register: ipaddress 24 | ignore_errors: True 25 | 26 | - name: Register Ports 27 | shell: 'cat /var/plexguide/server.ports' 28 | register: ports 29 | ignore_errors: True 30 | 31 | - name: Register HD Path 32 | shell: 'cat /var/plexguide/server.hd.path' 33 | register: path 34 | ignore_errors: True 35 | 36 | - name: Register Auth Path 37 | shell: 'cat /var/plexguide/server.ht' 38 | register: auth 39 | ignore_errors: True 40 | 41 | - name: Register Program Name 42 | shell: 'cat /tmp/program_var' 43 | register: program 44 | ignore_errors: True 45 | 46 | - name: check if user cname file exists 47 | stat: 48 | path: /var/plexguide/{{pgrole}}.cname 49 | register: ucname_check 50 | 51 | - name: Register user cname 52 | shell: 'cat /var/plexguide/{{pgrole}}.cname' 53 | register: ucname 54 | ignore_errors: True 55 | when: ucname_check.stat.exists == true 56 | 57 | - name: Register CName 58 | set_fact: 59 | cname: "" 60 | 61 | - name: Set cname 62 | set_fact: 63 | cname: ",{{ucname.stdout}}.{{domain.stdout}}" 64 | when: ucname_check.stat.exists == true and ucname.stdout != "" 65 | 66 | - name: check if user port file exists 67 | stat: 68 | path: /var/plexguide/{{pgrole}}.port 69 | register: ueport_check 70 | 71 | - name: Register External Port 72 | shell: 'cat /var/plexguide/{{pgrole}}.port' 73 | register: ueport 74 | ignore_errors: True 75 | when: ueport_check.stat.exists == true 76 | 77 | - name: Change extport 78 | set_fact: 79 | extport: "{{ueport.stdout}}" 80 | when: ueport_check.stat.exists and ueport.stdout != "" 81 | 82 | - name: Remove {{pgrole}} Container 83 | docker_container: 84 | name: '{{pgrole}}' 85 | state: absent 86 | ignore_errors: True 87 | 88 | - name: Storing Role Name 89 | shell: "echo '{{pgrole}}' > /tmp/program_var" 90 | ignore_errors: True 91 | 92 | # APPDATA 93 | - name: 'Creating appdata folder if it does not exist.' 94 | shell: 'mkdir -p /opt/appdata/{{pgrole}}' 95 | 96 | - name: 'Setting ownership on appdata' 97 | shell: 'chown 1000:1000 /opt/appdata/{{pgrole}}' 98 | when: '"plex" in pgrole' 99 | 100 | - name: 'Setting permissions on appdata' 101 | shell: 'chmod 775 /opt/appdata/{{pgrole}}' 102 | when: '"plex" in pgrole' 103 | 104 | - name: 'Setting ownership on appdata recursivley (this can take a while!)' 105 | shell: 'chown -R 1000:1000 /opt/appdata/{{pgrole}}' 106 | when: '"plex" not in pgrole' 107 | 108 | - name: 'Setting permissions on appdata recursivley (this can take a while!)' 109 | shell: 'chmod -R 775 /opt/appdata/{{pgrole}}' 110 | when: '"plex" not in pgrole' 111 | 112 | # OVERWRITE IMAGES ############################################################# 113 | - name: Check if Image Variable Exists 114 | stat: 115 | path: '/var/plexguide/image/{{pgrole}}' 116 | register: imagecheck 117 | 118 | - name: 'Transfer Image Variable' 119 | shell: 'cat /var/plexguide/image/{{pgrole}}' 120 | register: imagetemp 121 | when: imagecheck.stat.exists 122 | 123 | - name: 'If Fact Does Not Match - Disable TLD' 124 | set_fact: 125 | image: '{{imagetemp.stdout}}' 126 | when: imagecheck.stat.exists 127 | 128 | # TOP LEVEL DOMAIN INFO SET #################################################### 129 | 130 | - debug: msg="Stored TLD - {{pgrole}} must match {{toplevel.stdout}} for TLD" 131 | 132 | - name: 'If Fact Matches - Enable TLD' 133 | set_fact: 134 | tldset: ',{{domain.stdout}},www.{{domain.stdout}}' 135 | when: 'toplevel.stdout == pgrole' 136 | 137 | - debug: msg="TLDSET is now for {{toplevel.stdout}}" 138 | when: 'toplevel.stdout == pgrole' 139 | 140 | - name: 'If Fact Does Not Match - Disable TLD' 141 | set_fact: 142 | tldset: '' 143 | when: 'not toplevel.stdout == pgrole' 144 | 145 | - debug: msg="TLD does not apply" 146 | when: 'not toplevel.stdout == pgrole' 147 | 148 | # EXTERNAL PORT FOR END BANNER 149 | - name: Export Internal Port 150 | shell: 'echo {{extport}} > /tmp/program_port' 151 | ignore_errors: True 152 | 153 | # FOR AUTHENTICATION 154 | - name: 'Script Execute Part I' 155 | shell: 'bash /opt/pgshield/drop.sh' 156 | 157 | - name: 'Script Execute Part II' 158 | shell: 'cat /var/plexguide/auth.var' 159 | register: oauth 160 | 161 | - name: 'OAuth Exe' 162 | block: 163 | - name: Check if Anti Auth Variable Exists 164 | stat: 165 | path: '/var/plexguide/auth/{{pgrole}}' 166 | register: authcheck 167 | 168 | - name: 'Auth Check 1' 169 | set_fact: 170 | gauth: 'http://oauth:4181' 171 | when: not authcheck.stat.exists 172 | 173 | - name: 'Auth Check 2' 174 | set_fact: 175 | gauth: '' 176 | when: authcheck.stat.exists 177 | 178 | when: oauth.stdout == 'good' 179 | 180 | - name: 'OAuth Exe' 181 | set_fact: 182 | gauth: '' 183 | when: not oauth.stdout == 'good' 184 | 185 | - debug: msg="OAuth - {{oauth.stdout}}" 186 | -------------------------------------------------------------------------------- /apps/_cron.list: -------------------------------------------------------------------------------- 1 | portainer 2 | speedtest 3 | netdata 4 | alltube 5 | dockergc 6 | pgui 7 | watchtower 8 | -------------------------------------------------------------------------------- /apps/_cron.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Authors: Admin9705, Deiteq, and many PGBlitz Contributors 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - cron: 10 | name: Daily G/TDrive used space check | file checker 11 | special_time: 'daily' 12 | job: 'bash /opt/appdata/pgui/gtused.sh' 13 | state: absent 14 | ignore_errors: yes 15 | 16 | - cron: 17 | name: Daily G/TDrive used space check | file checker 18 | special_time: 'daily' 19 | job: 'bash /opt/appdata/pgui/check.sh' 20 | state: absent 21 | ignore_errors: yes 22 | 23 | - cron: 24 | name: Daily check for mgerfs / rclone new version 25 | special_time: 'daily' 26 | job: 'bash /opt/appdata/pgui/check.sh >/dev/null 2>&1' 27 | state: present 28 | 29 | - cron: 30 | name: Daily G/TDrive used space checker | file & folder 31 | special_time: 'daily' 32 | job: 'bash /opt/appdata/pgui/gtused.sh >/dev/null 2>&1' 33 | state: present -------------------------------------------------------------------------------- /apps/_downloaders.yml: -------------------------------------------------------------------------------- 1 | - name: Creating download paths 2 | file: 'path={{item}} state=directory mode=0775 owner=1000 group=1000' 3 | with_items: 4 | - '{{path.stdout}}/downloads/{{pgrole}}' 5 | - name: Creating incomplete paths 6 | file: 'path={{item}} state=directory mode=0775 owner=1000 group=1000' 7 | with_items: 8 | - '{{path.stdout}}/incomplete/{{pgrole}}' 9 | 10 | 11 | -------------------------------------------------------------------------------- /apps/_plugins.yml: -------------------------------------------------------------------------------- 1 | - name: Creating scripts and plugins paths 2 | file: 'path={{item}} state=directory mode=0775 owner=1000 group=1000' 3 | with_items: 4 | - '/opt/appdata/{{pgrole}}/scripts' 5 | - '/opt/appdata/{{pgrole}}/plugins' 6 | 7 | - name: 'Check if Templates Exist for {{pgrole}}' 8 | stat: 9 | path: '/opt/coreapps/apps/templates/{{pgrole}}' 10 | register: copycheck 11 | 12 | - name: 'Copying Scripts & Plugins' 13 | copy: 14 | src: '/opt/coreapps/apps/templates/{{pgrole}}' 15 | dest: '/opt/appdata/' 16 | directory_mode: yes 17 | force: yes 18 | owner: '1000' 19 | group: '1000' 20 | mode: 0775 21 | when: copycheck.stat.exists 22 | 23 | # scripts permissions 24 | - name: 'Setting permissions on scripts' 25 | shell: 'chmod -R 775 /opt/appdata/{{pgrole}}/scripts' 26 | - name: 'Setting permissions on plugins for {{pgrole}}' 27 | shell: 'chmod -R 775 /opt/appdata/{{pgrole}}/plugins' 28 | 29 | - name: set owner rights on script folder for {{pgrole}}' 30 | shell: 'chown -cR 1000:1000 /opt/appdata/{{pgrole}}/scripts' 31 | - name: set permission on plugin folder for {{pgrole}}' 32 | shell: 'chown -cR 1000:1000 /opt/appdata/{{pgrole}}/plugins' -------------------------------------------------------------------------------- /apps/crontabs/nzbget_cron.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: NZBGet Crontab remove logs daily 4 | # Authors: MrDoob 5 | # GNU: General Public License v3.0 6 | ################################################################################ 7 | --- 8 | - cron: 9 | name: Daily Remove {{pgrole}} logs 10 | special_time: 'daily' 11 | job: 'truncate -s 0 /opt/appdata/nzbget/nzbget.log' 12 | state: absent 13 | ignore_errors: yes 14 | 15 | - cron: 16 | name: Daily Remove {{pgrole}} logs 17 | special_time: 'daily' 18 | job: 'truncate -s 0 /opt/appdata/nzbget/nzbget.log 1>/dev/null 2>&1' 19 | state: present 20 | ignore_errors: yes -------------------------------------------------------------------------------- /apps/emby.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Author(s): Admin9705 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - hosts: localhost 10 | gather_facts: false 11 | tasks: 12 | # FACTS ####################################################################### 13 | - name: 'Set Known Facts' 14 | set_fact: 15 | pgrole: 'emby' 16 | intport: '8096' 17 | extport: '8096' 18 | intport2: '8920' 19 | extport2: '8920' 20 | image: 'emby/embyserver' 21 | 22 | # CORE (MANDATORY) ############################################################ 23 | - name: 'Including cron job' 24 | include_tasks: '/opt/coreapps/apps/_core.yml' 25 | 26 | - name: 'XML Check' 27 | stat: 28 | path: /opt/appdata/{{pgrole}}/config/system.xml 29 | register: xmlcheck 30 | 31 | # LABELS ###################################################################### 32 | - name: 'Adding Traefik for {{pgrole}}' 33 | set_fact: 34 | pg_labels: 35 | traefik.enable: 'true' 36 | traefik.port: '{{intport}}' 37 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 38 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 39 | traefik.frontend.headers.SSLRedirect: 'true' 40 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 41 | traefik.frontend.headers.STSPreload: 'true' 42 | traefik.frontend.headers.STSSeconds: '315360000' 43 | traefik.frontend.headers.browserXSSFilter: 'true' 44 | traefik.frontend.headers.contentTypeNosniff: 'true' 45 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 46 | traefik.frontend.headers.forceSTSHeader: 'true' 47 | 48 | - name: 'Setting {{pgrole}} Volumes' 49 | set_fact: 50 | pg_volumes: 51 | - '{{path.stdout}}:{{path.stdout}}' 52 | - '/opt/appdata/{{pgrole}}:/config' 53 | - '/opt/transcodes:/transcode' 54 | 55 | - name: 'Setting {{pgrole}} ENV' 56 | set_fact: 57 | pg_env: 58 | UID: '1000' 59 | GID: '1000' 60 | GIDLIST: '1000' 61 | NVIDIA_VISIBLE_DEVICES: 'all' 62 | NVIDIA_DRIVER_CAPABILITIES: 'compute,video,utility' 63 | 64 | # MAIN DEPLOYMENT ############################################################# 65 | - name: Check /dev/dri exists 66 | stat: 67 | path: '/dev/dri' 68 | register: dev_dri 69 | 70 | - name: 'Deploying {{pgrole}}' 71 | docker_container: 72 | name: '{{pgrole}}' 73 | image: '{{image}}' 74 | pull: yes 75 | published_ports: 76 | - '{{ports.stdout}}{{extport}}:{{intport}}' 77 | - '{{ports.stdout}}{{extport2}}:{{intport2}}' 78 | devices: "{{ '/dev/dri:/dev/dri' if dev_dri.stat.exists == True | default(false) else omit }}" 79 | volumes: '{{pg_volumes}}' 80 | env: '{{pg_env}}' 81 | purge_networks: yes 82 | restart_policy: unless-stopped 83 | networks: 84 | - name: plexguide 85 | aliases: 86 | - '{{pgrole}}' 87 | expose: '8096' 88 | expose: '8920' 89 | state: started 90 | labels: '{{pg_labels}}' 91 | 92 | # FIRST TIME CONFIGURATION ########################################################### 93 | - name: 'Configuring {{pgrole}} for first time use' 94 | block: 95 | - name: 'Pending XML Generation' 96 | wait_for: 97 | path: '/opt/appdata/{{pgrole}}/config/system.xml' 98 | state: present 99 | 100 | - name: 'Wait 5 Seconds' 101 | wait_for: 102 | timeout: 5 103 | 104 | - name: 'Stop {{pgrole}}' 105 | docker_container: 106 | name: '{{pgrole}}' 107 | state: stopped 108 | 109 | - name: 'Turn Off Reporting' 110 | xml: 111 | path: '/opt/appdata/{{pgrole}}/config/system.xml' 112 | xpath: /ServerConfiguration/EnableAnonymousUsageReporting 113 | value: 'false' 114 | 115 | - name: 'Restart {{pgrole}}' 116 | docker_container: 117 | name: '{{pgrole}}' 118 | state: started 119 | when: not xmlcheck.stat.exists 120 | -------------------------------------------------------------------------------- /apps/image/.old#p#lex: -------------------------------------------------------------------------------- 1 | plexinc/pms-docker:latest 2 | linuxserver/plex:latest 3 | -------------------------------------------------------------------------------- /apps/image/_image.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Author(s): Admin9705 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | 9 | # BAD INPUT 10 | badinput() { 11 | echo 12 | read -p '⛔️ ERROR - BAD INPUT! | PRESS [ENTER] ' typed /tmp/display$count 38 | count=$((count + 1)) 39 | done "/var/plexguide/image/$image" 46 | else badinput; fi 47 | } 48 | 49 | # END OF FUNCTIONS ############################################################ 50 | 51 | question1 52 | -------------------------------------------------------------------------------- /apps/image/netdata: -------------------------------------------------------------------------------- 1 | titpetric/netdata 2 | netdata/netdata:latest 3 | netdata/netdata:v1.19.0 4 | -------------------------------------------------------------------------------- /apps/image/nzbget: -------------------------------------------------------------------------------- 1 | linuxserver/nzbget 2 | linuxserver/nzbget:testing 3 | -------------------------------------------------------------------------------- /apps/image/ombi: -------------------------------------------------------------------------------- 1 | linuxserver/ombi 2 | linuxserver/ombi:v4-preview 3 | -------------------------------------------------------------------------------- /apps/image/plex: -------------------------------------------------------------------------------- 1 | plexinc/pms-docker:latest 2 | plexinc/pms-docker:beta 3 | -------------------------------------------------------------------------------- /apps/image/radarr: -------------------------------------------------------------------------------- 1 | linuxserver/radarr 2 | linuxserver/radarr:nightly 3 | hotio/radarr:musl 4 | aront/radarr 5 | hotio/radarr:musl 6 | -------------------------------------------------------------------------------- /apps/image/radarr4k: -------------------------------------------------------------------------------- 1 | linuxserver/radarr:nightly 2 | linuxserver/radarr 3 | aront/radarr 4 | hotio/radarr:musl 5 | -------------------------------------------------------------------------------- /apps/image/radarrhdr: -------------------------------------------------------------------------------- 1 | linuxserver/radarr:preview 2 | linuxserver/radarr 3 | aront/radarr 4 | hotio/radarr:musl 5 | -------------------------------------------------------------------------------- /apps/image/rutorrent: -------------------------------------------------------------------------------- 1 | linuxserver/rutorrent:v3.9-ls45 2 | linuxserver/rutorrent 3 | horjulf/rutorrent-autodl 4 | -------------------------------------------------------------------------------- /apps/image/sabnzbd: -------------------------------------------------------------------------------- 1 | linuxserver/sabnzbd 2 | sabnzbd/sabnzbd 3 | thedscman/sabnzbd 4 | wjbeckett/sabnzbd-mp4automator 5 | man1234/sabnzbdmp4 6 | -------------------------------------------------------------------------------- /apps/image/sonarr: -------------------------------------------------------------------------------- 1 | linuxserver/sonarr:preview 2 | linuxserver/sonarr 3 | aront/sonarr 4 | -------------------------------------------------------------------------------- /apps/image/sonarr4k: -------------------------------------------------------------------------------- 1 | linuxserver/sonarr:preview 2 | linuxserver/sonarr 3 | aront/sonarr -------------------------------------------------------------------------------- /apps/image/sonarrhdr: -------------------------------------------------------------------------------- 1 | linuxserver/sonarr:preview 2 | linuxserver/sonarr 3 | aront/sonarr -------------------------------------------------------------------------------- /apps/image/tautulli: -------------------------------------------------------------------------------- 1 | linuxserver/tautulli 2 | tautulli/tautulli 3 | -------------------------------------------------------------------------------- /apps/jackett.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Author(s): Admin9705 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - hosts: localhost 10 | gather_facts: false 11 | tasks: 12 | # FACTS ####################################################################### 13 | - name: 'Set Known Facts' 14 | set_fact: 15 | pgrole: 'jackett' 16 | intport: '9117' 17 | extport: '9117' 18 | image: 'linuxserver/jackett' 19 | 20 | # CORE (MANDATORY) ############################################################ 21 | - name: 'Including cron job' 22 | include_tasks: '/opt/coreapps/apps/_core.yml' 23 | 24 | # MIGRATIONS (MANDATORY) ############################################################ 25 | - name: Checking for old app data 26 | stat: 27 | path: '/opt/appdata/{{pgrole}}/Jackett/ServerConfig.json' 28 | register: olddatacheck 29 | 30 | - name: Migrating appdata 31 | shell: 'mv /opt/appdata/{{pgrole}}/Jackett/* /opt/appdata/{{pgrole}}' 32 | ignore_errors: yes 33 | when: olddatacheck.stat.exists 34 | 35 | - name: Migrating appdata 36 | shell: 'rmdir /opt/appdata/{{pgrole}}/Jackett' 37 | ignore_errors: yes 38 | when: olddatacheck.stat.exists 39 | 40 | - name: Checking for existing app data 41 | stat: 42 | path: '/opt/appdata/{{pgrole}}/ServerConfig.json' 43 | register: datacheck 44 | 45 | # LABELS ###################################################################### 46 | - name: 'Adding Traefik' 47 | set_fact: 48 | pg_labels: 49 | traefik.frontend.auth.forward.address: '{{gauth}}' 50 | traefik.enable: 'true' 51 | traefik.port: '{{intport}}' 52 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 53 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 54 | traefik.frontend.headers.SSLRedirect: 'true' 55 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 56 | traefik.frontend.headers.STSPreload: 'true' 57 | traefik.frontend.headers.STSSeconds: '315360000' 58 | traefik.frontend.headers.browserXSSFilter: 'true' 59 | traefik.frontend.headers.contentTypeNosniff: 'true' 60 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 61 | traefik.frontend.headers.forceSTSHeader: 'true' 62 | 63 | - name: 'Setting {{pgrole}} Volumes' 64 | set_fact: 65 | pg_volumes: 66 | - '{{path.stdout}}:{{path.stdout}}' 67 | - '/opt/appdata/{{pgrole}}:/config/Jackett' 68 | 69 | - name: 'Setting {{pgrole}} ENV' 70 | set_fact: 71 | pg_env: 72 | PUID: '1000' 73 | PGID: '1000' 74 | 75 | # MAIN DEPLOYMENT ############################################################# 76 | - name: 'Deploying {{pgrole}}' 77 | docker_container: 78 | name: '{{pgrole}}' 79 | image: '{{image}}' 80 | pull: yes 81 | published_ports: 82 | - '{{ports.stdout}}{{extport}}:{{intport}}' 83 | volumes: '{{pg_volumes}}' 84 | env: '{{pg_env}}' 85 | restart_policy: unless-stopped 86 | networks: 87 | - name: plexguide 88 | aliases: 89 | - '{{pgrole}}' 90 | state: started 91 | labels: '{{pg_labels}}' 92 | 93 | # CONFIGURATION #################################################### 94 | - name: 'Waiting for {{pgrole}} to initialize' 95 | wait_for: 96 | path: '/opt/appdata/{{pgrole}}/ServerConfig.json' 97 | state: present 98 | msg: ServerConfig.json creation failed 99 | 100 | - name: 'Stopping {{pgrole}}' 101 | docker_container: 102 | name: '{{pgrole}}' 103 | state: stopped 104 | 105 | # FIRST TIME CONFIGURATION #################################################### 106 | - name: 'Configuring {{pgrole}} for first time use' 107 | block: 108 | - name: Set torrent blackhole location 109 | lineinfile: 110 | path: '/opt/appdata/{{pgrole}}/ServerConfig.json' 111 | regexp: '\s*"BlackholeDir"\s*:.*' 112 | line: ' "BlackholeDir": "{{path.stdout}}/torrent/watch",' 113 | state: present 114 | when: not datacheck.stat.exists 115 | 116 | - name: Restart {{pgrole}} 117 | docker_container: 118 | name: '{{pgrole}}' 119 | state: started 120 | -------------------------------------------------------------------------------- /apps/jdownloader2.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: Jdownloader2 (OAuth security) 4 | # Author(s): timekills 5 | # URL: https://github.com/timekills/jdownloader2-for-Plexguide 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - hosts: localhost 10 | gather_facts: false 11 | tasks: 12 | # FACTS ####################################################################### 13 | 14 | - name: 'Set Known Facts' 15 | set_fact: 16 | pgrole: 'jdownloader2' 17 | intport: '5800' 18 | extport: '5802' 19 | intport2: '5902' 20 | extport2: '5902' 21 | intport3: '3129' 22 | extport3: '3129' 23 | image: 'jlesage/jdownloader-2' 24 | 25 | # CORE (MANDATORY) ############################################################ 26 | 27 | - name: 'Including cron job' 28 | include_tasks: '/opt/coreapps/apps/_core.yml' 29 | 30 | - name: 'Including plugins' 31 | include_tasks: '/opt/coreapps/apps/_plugins.yml' 32 | 33 | - name: 'Including folders' 34 | include_tasks: '/opt/coreapps/apps/_downloaders.yml' 35 | 36 | - name: 'Ini Check' 37 | stat: 38 | path: /opt/appdata/{{pgrole}}/core.conf 39 | register: inicheck 40 | 41 | # LABELS ###################################################################### 42 | - name: 'Adding Traefik' 43 | set_fact: 44 | pg_labels: 45 | traefik.enable: 'true' 46 | traefik.port: '{{intport}}' 47 | traefik.frontend.auth.forward.address: '{{gauth}}' 48 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 49 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 50 | traefik.frontend.headers.SSLRedirect: 'true' 51 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 52 | traefik.frontend.headers.STSPreload: 'true' 53 | traefik.frontend.headers.STSSeconds: '315360000' 54 | traefik.frontend.headers.browserXSSFilter: 'true' 55 | traefik.frontend.headers.contentTypeNosniff: 'true' 56 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 57 | traefik.frontend.headers.forceSTSHeader: 'true' 58 | 59 | - name: 'Setting {{pgrole}} Volumes' 60 | set_fact: 61 | pg_volumes: 62 | - '{{path.stdout}}:{{path.stdout}}' 63 | - '/opt/appdata/{{pgrole}}:/config' 64 | - '{{path.stdout}}/downloads/{{pgrole}}/:/output:rw' 65 | 66 | - name: 'Setting {{pgrole}} ENV' 67 | set_fact: 68 | pg_env: 69 | UID: '1000' 70 | GID: '1000' 71 | 72 | # MAIN DEPLOYMENT ############################################################# 73 | - name: 'Deploying {{pgrole}}' 74 | docker_container: 75 | name: '{{pgrole}}' 76 | image: '{{image}}' 77 | pull: yes 78 | published_ports: 79 | - '{{ports.stdout}}{{extport}}:{{intport}}' 80 | volumes: '{{pg_volumes}}' 81 | env: '{{pg_env}}' 82 | restart_policy: unless-stopped 83 | networks: 84 | - name: plexguide 85 | aliases: 86 | - '{{pgrole}}' 87 | state: started 88 | labels: '{{pg_labels}}' 89 | -------------------------------------------------------------------------------- /apps/jellyfin.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Author(s): Admin9705 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - hosts: localhost 10 | gather_facts: false 11 | tasks: 12 | # FACTS ####################################################################### 13 | - name: 'Set Known Facts' 14 | set_fact: 15 | pgrole: 'jellyfin' 16 | intport: '8096' 17 | extport: '9096' 18 | image: 'jellyfin/jellyfin:latest' 19 | 20 | # CORE (MANDATORY) ############################################################ 21 | - name: 'Including cron job' 22 | include_tasks: '/opt/coreapps/apps/_core.yml' 23 | 24 | - name: 'XML Check' 25 | stat: 26 | path: /opt/appdata/{{pgrole}}/config/system.xml 27 | register: xmlcheck 28 | 29 | # LABELS ###################################################################### 30 | - name: 'Adding Traefik' 31 | set_fact: 32 | pg_labels: 33 | traefik.enable: 'true' 34 | traefik.port: '{{intport}}' 35 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 36 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 37 | traefik.frontend.headers.SSLRedirect: 'true' 38 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 39 | traefik.frontend.headers.STSPreload: 'true' 40 | traefik.frontend.headers.STSSeconds: '315360000' 41 | traefik.frontend.headers.browserXSSFilter: 'true' 42 | traefik.frontend.headers.contentTypeNosniff: 'true' 43 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 44 | traefik.frontend.headers.forceSTSHeader: 'true' 45 | 46 | - name: 'Setting {{pgrole}} Volumes' 47 | set_fact: 48 | pg_volumes: 49 | - '{{path.stdout}}:{{path.stdout}}' 50 | - '/opt/appdata/{{pgrole}}:/config' 51 | - '/opt/transcodes:/transcode' 52 | - '/var/run/docker.sock:/var/run/docker.sock' 53 | 54 | - name: 'Setting {{pgrole}} ENV' 55 | set_fact: 56 | pg_env: 57 | GIDLIST: '1000' 58 | PUID: '1000' 59 | PGID: '1000' 60 | 61 | # MAIN DEPLOYMENT ############################################################# 62 | - name: 'Check' 63 | stat: 64 | path: '/dev/dri' 65 | register: dev_dri 66 | 67 | - name: 'Deploying {{pgrole}}' 68 | docker_container: 69 | name: '{{pgrole}}' 70 | image: '{{image}}' 71 | pull: yes 72 | user: 1000:1000 73 | published_ports: 74 | - '{{ports.stdout}}{{extport}}:{{intport}}' 75 | devices: "{{ '/dev/dri:/dev/dri' if dev_dri.stat.exists == True | default(false) else omit }}" 76 | volumes: '{{pg_volumes}}' 77 | env: '{{pg_env}}' 78 | restart_policy: unless-stopped 79 | networks: 80 | - name: plexguide 81 | aliases: 82 | - '{{pgrole}}' 83 | expose: '8096' 84 | state: started 85 | labels: '{{pg_labels}}' 86 | 87 | # FIRST TIME CONFIGURATION ########################################################### 88 | - name: 'Configuring {{pgrole}} for first time use' 89 | block: 90 | - name: 'Pending XML Generation' 91 | wait_for: 92 | path: '/opt/appdata/{{pgrole}}/config/system.xml' 93 | state: present 94 | 95 | - name: 'Wait 5 Seconds' 96 | wait_for: 97 | timeout: 5 98 | 99 | - name: 'Stop {{pgrole}}' 100 | docker_container: 101 | name: '{{pgrole}}' 102 | state: stopped 103 | 104 | - name: 'Turn Off Reporting' 105 | xml: 106 | path: '/opt/appdata/{{pgrole}}/config/system.xml' 107 | xpath: /ServerConfiguration/EnableAnonymousUsageReporting 108 | value: 'false' 109 | 110 | - name: 'Restart {{pgrole}}' 111 | docker_container: 112 | name: '{{pgrole}}' 113 | state: started 114 | when: not xmlcheck.stat.exists 115 | -------------------------------------------------------------------------------- /apps/lazylibrarian.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Author(s): Admin9705 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - hosts: localhost 10 | gather_facts: false 11 | tasks: 12 | # FACTS ####################################################################### 13 | - name: 'Set Known Facts' 14 | set_fact: 15 | pgrole: 'lazylibrarian' 16 | intport: '5299' 17 | extport: '5299' 18 | image: 'linuxserver/lazylibrarian' 19 | 20 | # CORE (MANDATORY) ############################################################ 21 | - name: 'Including cron job' 22 | include_tasks: '/opt/coreapps/apps/_core.yml' 23 | 24 | - name: 'Checking for existing app data' 25 | stat: 26 | path: /opt/appdata/{{pgrole}}/config.ini 27 | register: inicheck 28 | 29 | # LABELS ###################################################################### 30 | - name: 'Adding Traefik' 31 | set_fact: 32 | pg_labels: 33 | traefik.enable: 'true' 34 | traefik.port: '{{intport}}' 35 | traefik.frontend.auth.forward.address: '{{gauth}}' 36 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 37 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 38 | traefik.frontend.headers.SSLRedirect: 'true' 39 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 40 | traefik.frontend.headers.STSPreload: 'true' 41 | traefik.frontend.headers.STSSeconds: '315360000' 42 | traefik.frontend.headers.browserXSSFilter: 'true' 43 | traefik.frontend.headers.contentTypeNosniff: 'true' 44 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 45 | traefik.frontend.headers.forceSTSHeader: 'true' 46 | 47 | - name: 'Setting {{pgrole}} Volumes' 48 | set_fact: 49 | pg_volumes: 50 | - '{{path.stdout}}:{{path.stdout}}' 51 | - '/opt/appdata/{{pgrole}}:/config' 52 | 53 | - name: 'Setting {{pgrole}} ENV' 54 | set_fact: 55 | pg_env: 56 | PUID: '1000' 57 | PGID: '1000' 58 | 59 | # MAIN DEPLOYMENT ############################################################# 60 | - name: 'Deploying {{pgrole}}' 61 | docker_container: 62 | name: '{{pgrole}}' 63 | image: '{{image}}' 64 | pull: yes 65 | published_ports: 66 | - '{{ports.stdout}}{{extport}}:{{intport}}' 67 | volumes: '{{pg_volumes}}' 68 | env: '{{pg_env}}' 69 | restart_policy: unless-stopped 70 | networks: 71 | - name: plexguide 72 | aliases: 73 | - '{{pgrole}}' 74 | state: started 75 | labels: '{{pg_labels}}' 76 | 77 | # CONFIGURATION #################################################### 78 | 79 | - name: 'Waiting for {{pgrole}} to initialize' 80 | wait_for: 81 | path: '/opt/appdata/{{pgrole}}/config.ini' 82 | state: present 83 | delay: 5 84 | 85 | - name: 'Stopping {{pgrole}}' 86 | docker_container: 87 | name: '{{pgrole}}' 88 | state: stopped 89 | 90 | - name: Set eBooks library Location 91 | ini_file: 92 | path: '/opt/appdata/{{pgrole}}/config.ini' 93 | section: General 94 | option: ebook_dir 95 | value: '{{path.stdout}}/unionfs/ebooks' 96 | state: present 97 | 98 | - name: Set Audio Books library Location 99 | ini_file: 100 | path: '/opt/appdata/{{pgrole}}/config.ini' 101 | section: General 102 | option: audio_dir 103 | value: '{{path.stdout}}/unionfs/abooks' 104 | state: present 105 | 106 | - name: Set downloads location 107 | ini_file: 108 | path: '/opt/appdata/{{pgrole}}/config.ini' 109 | section: General 110 | option: download_dir 111 | value: '{{path.stdout}}/unionfs/sabnzbd/ebooks,{{path.stdout}}/unionfs/nzbget/ebooks,{{path.stdout}}/unionfs/rutorrent/ebooks,{{path.stdout}}/unionfs/qbittorrent/ebooks' 112 | state: present 113 | 114 | # FIRST TIME CONFIGURATION #################################################### 115 | 116 | - name: 'Configuring {{pgrole}} for first time use' 117 | block: 118 | - name: Enable audio tab 119 | ini_file: 120 | path: '/opt/appdata/{{pgrole}}/config.ini' 121 | section: General 122 | option: audio_tab 123 | value: 1 124 | state: present 125 | 126 | - name: Enable series tab 127 | ini_file: 128 | path: '/opt/appdata/{{pgrole}}/config.ini' 129 | section: General 130 | option: series_tab 131 | value: 1 132 | state: present 133 | 134 | - name: 'Configuring downloaders' 135 | block: 136 | - name: Set deluge host 137 | ini_file: 138 | path: '/opt/appdata/{{pgrole}}/config.ini' 139 | section: DELUGE 140 | option: deluge_host 141 | value: deluge 142 | state: present 143 | 144 | - name: Set deluge label 145 | ini_file: 146 | path: '/opt/appdata/{{pgrole}}/config.ini' 147 | section: DELUGE 148 | option: deluge_label 149 | value: ebooks 150 | state: present 151 | 152 | - name: Set deluge port 153 | ini_file: 154 | path: '/opt/appdata/{{pgrole}}/config.ini' 155 | section: DELUGE 156 | option: deluge_port 157 | value: 8112 158 | state: present 159 | 160 | - name: Set nzbget host 161 | ini_file: 162 | path: '/opt/appdata/{{pgrole}}/config.ini' 163 | section: NZBGet 164 | option: nzbget_host 165 | value: http://nzbget 166 | state: present 167 | 168 | - name: Set nzbget port 169 | ini_file: 170 | path: '/opt/appdata/{{pgrole}}/config.ini' 171 | section: NZBGet 172 | option: nzbget_port 173 | value: 6789 174 | state: present 175 | 176 | - name: Set nzbget label 177 | ini_file: 178 | path: '/opt/appdata/{{pgrole}}/config.ini' 179 | section: NZBGet 180 | option: nzbget_label 181 | value: ebooks 182 | state: present 183 | 184 | - name: Set qbittorrent host 185 | ini_file: 186 | path: '/opt/appdata/{{pgrole}}/config.ini' 187 | section: QBITTORRENT 188 | option: qbittorrent_host 189 | value: qbittorrent 190 | state: present 191 | 192 | - name: Set qbittorrent port 193 | ini_file: 194 | path: '/opt/appdata/{{pgrole}}/config.ini' 195 | section: QBITTORRENT 196 | option: qbittorrent_port 197 | value: 8080 198 | state: present 199 | 200 | - name: Set qbittorrent label 201 | ini_file: 202 | path: '/opt/appdata/{{pgrole}}/config.ini' 203 | section: QBITTORRENT 204 | option: qbittorrent_label 205 | value: ebooks 206 | state: present 207 | 208 | - name: Set sabnzbd host 209 | ini_file: 210 | path: '/opt/appdata/{{pgrole}}/config.ini' 211 | section: SABnzbd 212 | option: sab_host 213 | value: sabnzbd 214 | state: present 215 | 216 | - name: Set sabnzbd label 217 | ini_file: 218 | path: '/opt/appdata/{{pgrole}}/config.ini' 219 | section: SABnzbd 220 | option: sab_label 221 | value: ebooks 222 | state: present 223 | 224 | - name: Set rtorrent host 225 | ini_file: 226 | path: '/opt/appdata/{{pgrole}}/config.ini' 227 | section: RTORRENT 228 | option: rtorrent_host 229 | value: rutorrent 230 | state: present 231 | 232 | - name: Set rtorrent label 233 | ini_file: 234 | path: '/opt/appdata/{{pgrole}}/config.ini' 235 | section: RTORRENT 236 | option: rtorrent_label 237 | value: ebooks 238 | state: present 239 | 240 | - name: 'Configuring indexers' 241 | block: 242 | - name: Setup hydra on Newznab0 host 243 | ini_file: 244 | path: '/opt/appdata/{{pgrole}}/config.ini' 245 | section: Newznab0 246 | option: host 247 | value: nzbhydra:5076 248 | state: present 249 | 250 | - name: Setup hydra on Torznab0 host 251 | ini_file: 252 | path: '/opt/appdata/{{pgrole}}/config.ini' 253 | section: Torznab0 254 | option: host 255 | value: nzbhydra:5076/torznab 256 | state: present 257 | 258 | - name: Setup hydra on Torznab0 priority 259 | ini_file: 260 | path: '/opt/appdata/{{pgrole}}/config.ini' 261 | section: Torznab0 262 | option: dlpriority 263 | value: 1 264 | state: present 265 | 266 | when: not inicheck.stat.exists 267 | 268 | - name: Restart {{pgrole}} 269 | docker_container: 270 | name: '{{pgrole}}' 271 | state: started 272 | -------------------------------------------------------------------------------- /apps/lidarr.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Author(s): Admin9705 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - hosts: localhost 10 | gather_facts: false 11 | tasks: 12 | # FACTS ####################################################################### 13 | - name: 'Set Known Facts' 14 | set_fact: 15 | pgrole: 'lidarr' 16 | intport: '8686' 17 | extport: '8686' 18 | image: 'linuxserver/lidarr' 19 | 20 | # CORE (MANDATORY) ############################################################ 21 | - name: 'Including cron job' 22 | include_tasks: '/opt/coreapps/apps/_core.yml' 23 | 24 | # LABELS ###################################################################### 25 | - name: 'Adding Traefik' 26 | set_fact: 27 | pg_labels: 28 | traefik.enable: 'true' 29 | traefik.frontend.auth.forward.address: '{{gauth}}' 30 | traefik.port: '{{intport}}' 31 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 32 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 33 | traefik.frontend.headers.SSLRedirect: 'true' 34 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 35 | traefik.frontend.headers.STSPreload: 'true' 36 | traefik.frontend.headers.STSSeconds: '315360000' 37 | traefik.frontend.headers.browserXSSFilter: 'true' 38 | traefik.frontend.headers.contentTypeNosniff: 'true' 39 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 40 | traefik.frontend.headers.forceSTSHeader: 'true' 41 | 42 | - name: 'Setting PG Volumes' 43 | set_fact: 44 | pg_volumes: 45 | - '/etc/localtime:/etc/localtime:ro' 46 | - '{{path.stdout}}:{{path.stdout}}' 47 | - '/mnt:/mnt' 48 | - '/opt/appdata/{{pgrole}}:/config' 49 | 50 | - name: 'Setting PG ENV' 51 | set_fact: 52 | pg_env: 53 | PUID: '1000' 54 | PGID: '1000' 55 | 56 | # MAIN DEPLOYMENT ############################################################# 57 | - name: 'Deploying {{pgrole}}' 58 | docker_container: 59 | name: '{{pgrole}}' 60 | image: '{{image}}' 61 | pull: yes 62 | published_ports: 63 | - '{{ports.stdout}}{{extport}}:{{intport}}' 64 | volumes: '{{pg_volumes}}' 65 | env: '{{pg_env}}' 66 | restart_policy: unless-stopped 67 | networks: 68 | - name: plexguide 69 | aliases: 70 | - '{{pgrole}}' 71 | state: started 72 | labels: '{{pg_labels}}' 73 | -------------------------------------------------------------------------------- /apps/netdata.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: Netdata (Cloud update) 4 | # Author(s): Admin9705/netdata 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - hosts: localhost 10 | gather_facts: false 11 | tasks: 12 | # FACTS ####################################################################### 13 | - name: 'Set Known Facts' 14 | set_fact: 15 | pgrole: 'netdata' 16 | intport: '19999' 17 | extport: '19999' 18 | image: 'netdata/netdata' 19 | 20 | # CORE (MANDATORY) ############################################################ 21 | - name: 'Including cron job' 22 | include_tasks: '/opt/coreapps/apps/_core.yml' 23 | 24 | # LABELS ###################################################################### 25 | - name: 'Adding Traefik' 26 | set_fact: 27 | pg_labels: 28 | traefik.frontend.auth.forward.address: '{{gauth}}' 29 | traefik.enable: 'true' 30 | traefik.port: '{{intport}}' 31 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 32 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 33 | traefik.frontend.headers.SSLRedirect: 'true' 34 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 35 | traefik.frontend.headers.STSPreload: 'true' 36 | traefik.frontend.headers.STSSeconds: '315360000' 37 | traefik.frontend.headers.browserXSSFilter: 'true' 38 | traefik.frontend.headers.contentTypeNosniff: 'true' 39 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 40 | traefik.frontend.headers.forceSTSHeader: 'true' 41 | 42 | - name: 'Setting PG Volumes' 43 | set_fact: 44 | pg_volumes: 45 | - '/opt/appdata/{{pgrole}}/netdatalib:/var/lib/netdata:rw' 46 | - '/opt/appdata/{{pgrole}}/netdatacache:/var/cache/netdata:rw' 47 | - '{{path.stdout}}:{{path.stdout}}' 48 | - '/etc/passwd:/host/etc/passwd:ro' 49 | - '/etc/group:/host/etc/group:ro' 50 | - '/proc:/host/proc:ro' 51 | - '/sys:/host/sys:ro' 52 | - '/etc/os-release:/host/etc/os-release:ro' 53 | - '/etc/localtime:/etc/localtime:ro' 54 | - '/var/run/docker.sock:/var/run/docker.sock' 55 | 56 | - name: 'Setting PG ENV' 57 | set_fact: 58 | pg_env: 59 | PUID: '1000' 60 | PGID: '1000' 61 | 62 | # MAIN DEPLOYMENT ############################################################# 63 | - name: 'Deploying {{pgrole}}' 64 | docker_container: 65 | name: '{{pgrole}}' 66 | image: '{{image}}' 67 | pull: yes 68 | hostname: '{{domain.stdout}}' 69 | capabilities: 70 | - SYS_PTRACE 71 | published_ports: 72 | - '{{ports.stdout}}{{extport}}:{{intport}}' 73 | volumes: '{{pg_volumes}}' 74 | env: '{{pg_env}}' 75 | restart_policy: unless-stopped 76 | networks: 77 | - name: plexguide 78 | aliases: 79 | - '{{pgrole}}' 80 | security_opts: 81 | - apparmor:unconfined 82 | state: started 83 | labels: '{{pg_labels}}' 84 | -------------------------------------------------------------------------------- /apps/nzbget.yml: -------------------------------------------------------------------------------- 1 | # 2 | # Title: NZBGet 3 | # Author(s): FUU off Brandings 4 | # GNU: General Public License v3.0 5 | ################################################################################# 6 | --- 7 | - hosts: localhost 8 | gather_facts: false 9 | tasks: 10 | # FACTS ####################################################################### 11 | 12 | - name: 'Set Known Facts' 13 | set_fact: 14 | pgrole: 'nzbget' 15 | intport: '6789' 16 | extport: '6789' 17 | image: 'linuxserver/nzbget:latest' 18 | 19 | # CORE (MANDATORY) ############################################################ 20 | - name: 'Including cron job' 21 | include_tasks: '/opt/coreapps/apps/_core.yml' 22 | 23 | - name: 'Including {{pgrole}} log job' 24 | include_tasks: '/opt/coreapps/apps/crontabs/nzbget_cron.yml' 25 | 26 | - name: 'Including folders' 27 | include_tasks: '/opt/coreapps/apps/_downloaders.yml' 28 | 29 | - name: Create nzb folder 30 | file: 'path={{item}} state=directory mode=0775 owner=1000 group=1000' 31 | with_items: 32 | - '{{path.stdout}}/nzb' 33 | 34 | - name: 'Including plugins' 35 | include_tasks: '/opt/coreapps/apps/_plugins.yml' 36 | 37 | - name: 'Checking for existing app data' 38 | stat: 39 | path: /opt/appdata/{{pgrole}}/nzbget.conf 40 | register: confcheck 41 | 42 | - name: 'Including Tasks' 43 | include_tasks: '/opt/coreapps/apps/templates/tasks/dynamic.yml' 44 | 45 | # LABELS ###################################################################### 46 | - name: 'Adding Traefik' 47 | set_fact: 48 | pg_labels: 49 | traefik.enable: 'true' 50 | traefik.port: '{{intport}}' 51 | traefik.frontend.auth.forward.address: '{{gauth}}' 52 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 53 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 54 | traefik.frontend.headers.SSLRedirect: 'true' 55 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 56 | traefik.frontend.headers.STSPreload: 'true' 57 | traefik.frontend.headers.STSSeconds: '315360000' 58 | traefik.frontend.headers.browserXSSFilter: 'true' 59 | traefik.frontend.headers.contentTypeNosniff: 'true' 60 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 61 | traefik.frontend.headers.forceSTSHeader: 'true' 62 | 63 | - name: 'Setting {{pgrole}} Volumes' 64 | set_fact: 65 | pg_volumes: 66 | - '{{path.stdout}}:{{path.stdout}}' 67 | - '/opt/appdata/{{pgrole}}:/config' 68 | - '/tmp:/tmp' 69 | 70 | - name: 'Setting {{pgrole}} ENV' 71 | set_fact: 72 | pg_env: 73 | PUID: '1000' 74 | PGID: '1000' 75 | LC_ALL: 'C' 76 | 77 | # MAIN DEPLOYMENT ############################################################# 78 | - name: 'Deploying {{pgrole}}' 79 | docker_container: 80 | name: '{{pgrole}}' 81 | image: '{{image}}' 82 | pull: yes 83 | published_ports: 84 | - '{{ports.stdout}}{{extport}}:{{intport}}' 85 | volumes: '{{pg_volumes}}' 86 | env: '{{pg_env}}' 87 | restart_policy: unless-stopped 88 | networks: 89 | - name: plexguide 90 | aliases: 91 | - '{{pgrole}}' 92 | state: started 93 | labels: '{{pg_labels}}' 94 | 95 | # Correct Scripts Folder ################################### 96 | - name: Check scripts folder 97 | stat: 98 | path: '/opt/appdata/{{pgrole}}/scripts' 99 | register: scripts 100 | 101 | - name: Overwrite {{pgrole}} existing directory 102 | file: 'path={{item}} state=directory mode=0775 owner=1000 group=1000 recurse=yes' 103 | with_items: 104 | - '/opt/appdata/{{pgrole}}/scripts' 105 | when: 106 | - scripts.stat.exists == True 107 | 108 | - name: 'Install {{pgrole}} scripts from template' 109 | include_tasks: '/opt/coreapps/apps/templates/nzbget/scripts.yml' 110 | when: 111 | - scripts.stat.exists == True 112 | 113 | - name: Install Clinton-hall {{pgrole}} scripts from scratch 114 | unarchive: 115 | src: 'https://github.com/clinton-hall/GetScripts/archive/master.zip' 116 | dest: '/opt/appdata/{{pgrole}}/scripts/' 117 | keep_newer: yes 118 | owner: '1000' 119 | group: '1000' 120 | mode: 0775 121 | copy: no 122 | when: 123 | - scripts.stat.exists == True 124 | 125 | # CONFIGURATION ############################################################# 126 | - name: 'Waiting for {{pgrole}} to initialize' 127 | wait_for: 128 | path: '/opt/appdata/{{pgrole}}/nzbget.conf' 129 | state: present 130 | delay: 5 131 | 132 | - name: 'Stopping {{pgrole}}' 133 | docker_container: 134 | name: '{{pgrole}}' 135 | state: stopped 136 | 137 | - name: Set Main Location 138 | lineinfile: 139 | path: '/opt/appdata/{{pgrole}}/nzbget.conf' 140 | regexp: '^MainDir\s*=.*' 141 | line: 'MainDir=/config' 142 | state: present 143 | 144 | - name: Set download location 145 | lineinfile: 146 | path: '/opt/appdata/{{pgrole}}/nzbget.conf' 147 | regexp: '^DestDir\s*=.*' 148 | line: 'DestDir={{path.stdout}}/downloads/{{pgrole}}' 149 | state: present 150 | 151 | - name: Set incomplete location 152 | lineinfile: 153 | path: '/opt/appdata/{{pgrole}}/nzbget.conf' 154 | regexp: '^InterDir\s*=.*' 155 | line: 'InterDir={{path.stdout}}/incomplete/{{pgrole}}' 156 | state: present 157 | 158 | - name: Set TempDir 159 | lineinfile: 160 | path: '/opt/appdata/{{pgrole}}/nzbget.conf' 161 | regexp: '^TempDir\s*=.*' 162 | line: 'TempDir=/tmp' 163 | state: present 164 | 165 | - name: Set NzbDir Location 166 | lineinfile: 167 | path: '/opt/appdata/{{pgrole}}/nzbget.conf' 168 | regexp: '^NzbDir\s*=.*' 169 | line: 'NzbDir={{path.stdout}}/nzb' 170 | state: present 171 | 172 | - name: ScriptDir 173 | lineinfile: 174 | path: '/opt/appdata/{{pgrole}}/nzbget.conf' 175 | regexp: '^ScriptDir\s*=.*' 176 | line: 'ScriptDir=${MainDir}/scripts' 177 | state: present 178 | 179 | # FIRST TIME CONFIGURATION ############################################################# 180 | - name: 'Configuring {{pgrole}} for first time use' 181 | block: 182 | - name: Lowercase & Set Movie Category 183 | lineinfile: 184 | path: '/opt/appdata/{{pgrole}}/nzbget.conf' 185 | regexp: '^Category1.Name\s*=.*' 186 | line: 'Category1.Name=movies' 187 | state: present 188 | 189 | - name: Set Location of Movies 190 | lineinfile: 191 | path: '/opt/appdata/{{pgrole}}/nzbget.conf' 192 | regexp: '^Category1.DestDir\s*=.*' 193 | line: 'Category1.DestDir=' 194 | state: present 195 | 196 | - name: Lowercase & Set TV Category 197 | lineinfile: 198 | path: '/opt/appdata/{{pgrole}}/nzbget.conf' 199 | regexp: '^Category2.Name\s*=.*' 200 | line: 'Category2.Name=tv' 201 | state: present 202 | 203 | - name: Set Location of TV 204 | lineinfile: 205 | path: '/opt/appdata/{{pgrole}}/nzbget.conf' 206 | regexp: '^Category2.DestDir\s*=.*' 207 | line: 'Category2.DestDir=' 208 | state: present 209 | 210 | - name: Lowercase & Set Music Category 211 | lineinfile: 212 | path: '/opt/appdata/{{pgrole}}/nzbget.conf' 213 | regexp: '^Category3.Name\s*=.*' 214 | line: 'Category3.Name=music' 215 | state: present 216 | 217 | - name: Set Location of Music 218 | lineinfile: 219 | path: '/opt/appdata/{{pgrole}}/nzbget.conf' 220 | regexp: '^Category3.DestDir\s*=.*' 221 | line: 'Category3.DestDir=' 222 | state: present 223 | 224 | - name: Lowercase & Set EBook Category 225 | lineinfile: 226 | path: '/opt/appdata/{{pgrole}}/nzbget.conf' 227 | regexp: '^Category4.Name\s*=.*' 228 | line: 'Category4.Name=ebooks' 229 | state: present 230 | 231 | - name: Set Location of EBooks 232 | lineinfile: 233 | path: '/opt/appdata/{{pgrole}}/nzbget.conf' 234 | regexp: '^Category4.DestDir\s*=.*' 235 | line: 'Category4.DestDir=' 236 | state: present 237 | 238 | - name: Lowercase & Set abook Category 239 | lineinfile: 240 | path: '/opt/appdata/{{pgrole}}/nzbget.conf' 241 | regexp: 'Category5.Name\s*=.*' 242 | line: 'Category5.Name=abooks' 243 | state: present 244 | 245 | - name: Set Location of aBooks 246 | lineinfile: 247 | path: '/opt/appdata/{{pgrole}}/nzbget.conf' 248 | regexp: 'Category5.DestDir\s*=.*' 249 | line: 'Category5.DestDir=' 250 | state: present 251 | 252 | - name: Default User 253 | lineinfile: 254 | path: '/opt/appdata/{{pgrole}}/nzbget.conf' 255 | regexp: '^ControlUsername\s*=.*' 256 | line: 'ControlUsername=' 257 | state: present 258 | 259 | - name: Default Password 260 | lineinfile: 261 | path: '/opt/appdata/{{pgrole}}/nzbget.conf' 262 | regexp: 'ControlPassword\s*=.*' 263 | line: 'ControlPassword=' 264 | state: present 265 | 266 | - name: DirectUnpack Set to On 267 | lineinfile: 268 | path: '/opt/appdata/{{pgrole}}/nzbget.conf' 269 | regexp: '^DirectUnpack\s*=.*' 270 | line: 'DirectUnpack=yes' 271 | state: present 272 | 273 | - name: HealthCheck 274 | lineinfile: 275 | path: '/opt/appdata/{{pgrole}}/nzbget.conf' 276 | regexp: '^HealthCheck\s*=.*' 277 | line: 'HealthCheck=Delete' 278 | state: present 279 | 280 | - name: Set DiskSpace 281 | lineinfile: 282 | path: '/opt/appdata/{{pgrole}}/nzbget.conf' 283 | regexp: '^DiskSpace\s*=.*' 284 | line: 'DiskSpace=25000' 285 | state: present 286 | 287 | - name: Remove Generic Task 288 | lineinfile: 289 | path: '/opt/appdata/{{pgrole}}/nzbget.conf' 290 | regexp: '{{ item.regexp }}' 291 | state: absent 292 | with_items: 293 | - { regexp: '.Task1\.Time\=' } 294 | - { regexp: '.Task1\.WeekDays\=' } 295 | - { regexp: '.Task1\.Command\=' } 296 | - { regexp: '.Task1\.Param\=' } 297 | 298 | - name: Unpause 299 | blockinfile: 300 | path: '/opt/appdata/{{pgrole}}/nzbget.conf' 301 | block: | 302 | Task1.Time=*,*:00,*:30 303 | Task1.WeekDays=1-7 304 | Task1.Command=UnpauseDownload 305 | Task1.Param= 306 | insertafter: '^### SCHEDULER' 307 | when: not confcheck.stat.exists 308 | 309 | - name: Restart {{pgrole}} 310 | docker_container: 311 | name: '{{pgrole}}' 312 | state: started 313 | -------------------------------------------------------------------------------- /apps/nzbhydra.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Author(s): Admin9705 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - hosts: localhost 10 | gather_facts: false 11 | tasks: 12 | # FACTS ####################################################################### 13 | - name: 'Set Known Facts' 14 | set_fact: 15 | pgrole: 'nzbhydra' 16 | intport: '5076' 17 | extport: '5076' 18 | image: 'linuxserver/nzbhydra2' 19 | 20 | # CORE (MANDATORY) ############################################################ 21 | - name: 'Including cron job' 22 | include_tasks: '/opt/coreapps/apps/_core.yml' 23 | 24 | # LABELS ###################################################################### 25 | - name: 'Adding Traefik' 26 | set_fact: 27 | pg_labels: 28 | traefik.enable: 'true' 29 | traefik.port: '{{intport}}' 30 | traefik.frontend.auth.forward.address: '{{gauth}}' 31 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 32 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 33 | traefik.frontend.headers.SSLRedirect: 'true' 34 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 35 | traefik.frontend.headers.STSPreload: 'true' 36 | traefik.frontend.headers.STSSeconds: '315360000' 37 | traefik.frontend.headers.browserXSSFilter: 'true' 38 | traefik.frontend.headers.contentTypeNosniff: 'true' 39 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 40 | traefik.frontend.headers.forceSTSHeader: 'true' 41 | 42 | - name: 'Setting {{pgrole}} Volumes' 43 | set_fact: 44 | pg_volumes: 45 | - '{{path.stdout}}:{{path.stdout}}' 46 | - '/opt/appdata/{{pgrole}}:/config' 47 | - '{{path.stdout}}/torrent:{{path.stdout}}/torrent' 48 | 49 | - name: 'Setting {{pgrole}} ENV' 50 | set_fact: 51 | pg_env: 52 | PUID: '1000' 53 | PGID: '1000' 54 | 55 | # MAIN DEPLOYMENT ############################################################# 56 | - name: 'Deploying {{pgrole}}' 57 | docker_container: 58 | name: '{{pgrole}}' 59 | image: '{{image}}' 60 | pull: yes 61 | published_ports: 62 | - '{{ports.stdout}}{{extport}}:{{intport}}' 63 | volumes: '{{pg_volumes}}' 64 | env: '{{pg_env}}' 65 | restart_policy: unless-stopped 66 | networks: 67 | - name: plexguide 68 | aliases: 69 | - '{{pgrole}}' 70 | state: started 71 | labels: '{{pg_labels}}' 72 | -------------------------------------------------------------------------------- /apps/ombi.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Author(s): Admin9705 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - hosts: localhost 10 | gather_facts: false 11 | tasks: 12 | # FACTS ####################################################################### 13 | 14 | - name: 'Set Known Facts' 15 | set_fact: 16 | pgrole: 'ombi' 17 | intport: '3579' 18 | extport: '3579' 19 | image: 'linuxserver/ombi' 20 | 21 | # CORE (MANDATORY) ############################################################ 22 | - name: 'Including cron job' 23 | include_tasks: '/opt/coreapps/apps/_core.yml' 24 | 25 | # PRETASKS #################################################################### 26 | - name: Check JSON exists 27 | stat: 28 | path: '/opt/appdata/{{pgrole}}/appsettings.json' 29 | register: jsonfile 30 | 31 | - name: 'Download {{pgrole}} appsettings.json config file' 32 | get_url: 33 | url: https://raw.githubusercontent.com/tidusjar/Ombi/master/src/Ombi/appsettings.json 34 | dest: /opt/appdata/{{pgrole}}/appsettings.json 35 | owner: '1000' 36 | group: '1000' 37 | force: no 38 | ignore_errors: True 39 | when: jsonfile.stat.exists == False 40 | 41 | # LABELS ###################################################################### 42 | - name: 'Adding Traefik' 43 | set_fact: 44 | pg_labels: 45 | traefik.enable: 'true' 46 | traefik.port: '{{intport}}' 47 | traefik.frontend.auth.forward.address: '{{gauth}}' 48 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 49 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 50 | traefik.frontend.headers.SSLRedirect: 'true' 51 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 52 | traefik.frontend.headers.STSPreload: 'true' 53 | traefik.frontend.headers.STSSeconds: '315360000' 54 | traefik.frontend.headers.browserXSSFilter: 'true' 55 | traefik.frontend.headers.contentTypeNosniff: 'true' 56 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 57 | traefik.frontend.headers.forceSTSHeader: 'true' 58 | 59 | - name: 'Setting {{pgrole}} Volumes' 60 | set_fact: 61 | pg_volumes: 62 | - '/opt/appdata/{{pgrole}}:/config' 63 | - '/opt/appdata/{{pgrole}}/appsettings.json:/opt/{{pgrole}}/appsettings.json' 64 | 65 | - name: 'Setting {{pgrole}} ENV' 66 | set_fact: 67 | pg_env: 68 | PUID: '1000' 69 | PGID: '1000' 70 | 71 | # MAIN DEPLOYMENT ############################################################# 72 | 73 | - name: 'Deploying {{pgrole}}' 74 | docker_container: 75 | name: '{{pgrole}}' 76 | image: '{{image}}' 77 | pull: yes 78 | published_ports: 79 | - '{{ports.stdout}}{{extport}}:{{intport}}' 80 | volumes: '{{pg_volumes}}' 81 | env: '{{pg_env}}' 82 | restart_policy: unless-stopped 83 | networks: 84 | - name: plexguide 85 | aliases: 86 | - '{{pgrole}}' 87 | state: started 88 | labels: '{{pg_labels}}' 89 | -------------------------------------------------------------------------------- /apps/ombi4k.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: Ombi4k (Reference Title File) 4 | # Author(s): Admin9705; timekills mod 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - hosts: localhost 10 | gather_facts: false 11 | tasks: 12 | # FACTS ####################################################################### 13 | 14 | - name: 'Set Known Facts' 15 | set_fact: 16 | pgrole: 'ombi4k' 17 | intport: '3579' 18 | extport: '3580' 19 | image: 'linuxserver/ombi' 20 | 21 | # CORE (MANDATORY) ############################################################ 22 | - name: 'Including cron job' 23 | include_tasks: '/opt/coreapps/apps/_core.yml' 24 | 25 | # PRETASKS #################################################################### 26 | - name: Check JSON exists 27 | stat: 28 | path: '/opt/appdata/{{pgrole}}/appsettings.json' 29 | register: jsonfile 30 | 31 | - name: 'Download {{pgrole}} appsettings.json config file' 32 | get_url: 33 | url: https://raw.githubusercontent.com/tidusjar/Ombi/master/src/Ombi/appsettings.json 34 | dest: /opt/appdata/{{pgrole}}/appsettings.json 35 | owner: '1000' 36 | group: '1000' 37 | force: no 38 | ignore_errors: True 39 | when: jsonfile.stat.exists == False 40 | 41 | # LABELS ###################################################################### 42 | - name: 'Adding Traefik' 43 | set_fact: 44 | pg_labels: 45 | traefik.enable: 'true' 46 | traefik.port: '{{intport}}' 47 | traefik.frontend.auth.forward.address: '{{gauth}}' 48 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 49 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 50 | traefik.frontend.headers.SSLRedirect: 'true' 51 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 52 | traefik.frontend.headers.STSPreload: 'true' 53 | traefik.frontend.headers.STSSeconds: '315360000' 54 | traefik.frontend.headers.browserXSSFilter: 'true' 55 | traefik.frontend.headers.contentTypeNosniff: 'true' 56 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 57 | traefik.frontend.headers.forceSTSHeader: 'true' 58 | 59 | - name: 'Setting {{pgrole}} Volumes' 60 | set_fact: 61 | pg_volumes: 62 | - '/opt/appdata/{{pgrole}}:/config' 63 | - '/opt/appdata/{{pgrole}}/appsettings.json:/opt/{{pgrole}}/appsettings.json' 64 | 65 | - name: 'Setting {{pgrole}} ENV' 66 | set_fact: 67 | pg_env: 68 | PUID: '1000' 69 | PGID: '1000' 70 | 71 | # MAIN DEPLOYMENT ############################################################# 72 | 73 | - name: 'Deploying {{pgrole}}' 74 | docker_container: 75 | name: '{{pgrole}}' 76 | image: '{{image}}' 77 | pull: yes 78 | published_ports: 79 | - '{{ports.stdout}}{{extport}}:{{intport}}' 80 | volumes: '{{pg_volumes}}' 81 | env: '{{pg_env}}' 82 | restart_policy: unless-stopped 83 | networks: 84 | - name: plexguide 85 | aliases: 86 | - '{{pgrole}}' 87 | state: started 88 | labels: '{{pg_labels}}' 89 | -------------------------------------------------------------------------------- /apps/ombiHDR.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: OmbiHDR 4 | # Author(s): Admin9705; timekills mod 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - hosts: localhost 10 | gather_facts: false 11 | tasks: 12 | # FACTS ####################################################################### 13 | 14 | - name: 'Set Known Facts' 15 | set_fact: 16 | pgrole: 'ombiHDR' 17 | intport: '3579' 18 | extport: '3581' 19 | image: 'linuxserver/ombi' 20 | 21 | # CORE (MANDATORY) ############################################################ 22 | - name: 'Including cron job' 23 | include_tasks: '/opt/coreapps/apps/_core.yml' 24 | 25 | # PRETASKS #################################################################### 26 | - name: Check JSON exists 27 | stat: 28 | path: '/opt/appdata/{{pgrole}}/appsettings.json' 29 | register: jsonfile 30 | 31 | - name: 'Download {{pgrole}} appsettings.json config file' 32 | get_url: 33 | url: https://raw.githubusercontent.com/tidusjar/Ombi/master/src/Ombi/appsettings.json 34 | dest: /opt/appdata/{{pgrole}}/appsettings.json 35 | owner: '1000' 36 | group: '1000' 37 | force: no 38 | ignore_errors: True 39 | when: jsonfile.stat.exists == False 40 | 41 | # LABELS ###################################################################### 42 | - name: 'Adding Traefik' 43 | set_fact: 44 | pg_labels: 45 | traefik.enable: 'true' 46 | traefik.port: '{{intport}}' 47 | traefik.frontend.auth.forward.address: '{{gauth}}' 48 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 49 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 50 | traefik.frontend.headers.SSLRedirect: 'true' 51 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 52 | traefik.frontend.headers.STSPreload: 'true' 53 | traefik.frontend.headers.STSSeconds: '315360000' 54 | traefik.frontend.headers.browserXSSFilter: 'true' 55 | traefik.frontend.headers.contentTypeNosniff: 'true' 56 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 57 | traefik.frontend.headers.forceSTSHeader: 'true' 58 | 59 | - name: 'Setting {{pgrole}} Volumes' 60 | set_fact: 61 | pg_volumes: 62 | - '/opt/appdata/{{pgrole}}:/config' 63 | - '/opt/appdata/{{pgrole}}/appsettings.json:/opt/{{pgrole}}/appsettings.json' 64 | 65 | - name: 'Setting {{pgrole}} ENV' 66 | set_fact: 67 | pg_env: 68 | PUID: '1000' 69 | PGID: '1000' 70 | 71 | # MAIN DEPLOYMENT ############################################################# 72 | 73 | - name: 'Deploying {{pgrole}}' 74 | docker_container: 75 | name: '{{pgrole}}' 76 | image: '{{image}}' 77 | pull: yes 78 | published_ports: 79 | - '{{ports.stdout}}{{extport}}:{{intport}}' 80 | volumes: '{{pg_volumes}}' 81 | env: '{{pg_env}}' 82 | restart_policy: unless-stopped 83 | networks: 84 | - name: plexguide 85 | aliases: 86 | - '{{pgrole}}' 87 | state: started 88 | labels: '{{pg_labels}}' 89 | -------------------------------------------------------------------------------- /apps/overseer.yml: -------------------------------------------------------------------------------- 1 | #!/bin/ansible 2 | # 3 | # Title: PGBlitz (overseer) 4 | # Author(s): MrDoob / Timmeh 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - hosts: localhost 10 | gather_facts: false 11 | tasks: 12 | # FACTS ####################################################################### 13 | - name: 'Set Known Facts' 14 | set_fact: 15 | pgrole: 'overseerr' 16 | intport: '5055' 17 | extport: '5055' 18 | image: 'sctx/overseerr' 19 | 20 | # CORE (MANDATORY) ############################################################ 21 | - name: 'Including cron job' 22 | include_tasks: '/opt/coreapps/apps/_core.yml' 23 | 24 | # LABELS ###################################################################### 25 | - name: 'Adding Traefik' 26 | set_fact: 27 | pg_labels: 28 | traefik.enable: 'true' 29 | traefik.port: '{{intport}}' 30 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 31 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 32 | traefik.frontend.headers.SSLRedirect: 'true' 33 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 34 | traefik.frontend.headers.STSPreload: 'true' 35 | traefik.frontend.headers.STSSeconds: '315360000' 36 | traefik.frontend.headers.browserXSSFilter: 'true' 37 | traefik.frontend.headers.contentTypeNosniff: 'true' 38 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 39 | traefik.frontend.headers.forceSTSHeader: 'true' 40 | traefik.frontend.redirect.entryPoint: 'https' 41 | 42 | - name: 'Setting PG Volumes' 43 | set_fact: 44 | pg_volumes: 45 | - '/opt/appdata/{{pgrole}}/config:/app/config:rw' 46 | - '/etc/localtime:/etc/localtime:ro' 47 | 48 | - name: 'Setting PG ENV' 49 | set_fact: 50 | pg_env: 51 | PUID: '1000' 52 | PGID: '1000' 53 | TZ: 'UTC' 54 | LOG_LEVEL: 'info' 55 | 56 | # MAIN DEPLOYMENT ############################################################ 57 | - name: 'Deploying {{pgrole}}' 58 | docker_container: 59 | name: '{{pgrole}}' 60 | image: '{{image}}' 61 | pull: yes 62 | published_ports: 63 | - '{{ports.stdout}}{{extport}}:{{intport}}' 64 | volumes: '{{pg_volumes}}' 65 | env: '{{pg_env}}' 66 | restart_policy: unless-stopped 67 | networks: 68 | - name: plexguide 69 | aliases: 70 | - '{{pgrole}}' 71 | state: started 72 | labels: '{{pg_labels}}' 73 | -------------------------------------------------------------------------------- /apps/pgui.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Author(s): Admin9705 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - hosts: localhost 10 | gather_facts: false 11 | tasks: 12 | # FACTS ####################################################################### 13 | - name: 'Set Known Facts' 14 | set_fact: 15 | pgrole: 'pgui' 16 | intport: '80' 17 | extport: '8555' 18 | image: 'richarvey/nginx-php-fpm:1.10.3' 19 | 20 | # CORE (MANDATORY) ############################################################ 21 | - name: 'Including cron job' 22 | include_tasks: '/opt/coreapps/apps/_core.yml' 23 | 24 | - name: Install File 25 | template: 26 | src: /opt/pgui/templates/index.php 27 | dest: /opt/appdata/pgui/index.php 28 | force: yes 29 | owner: '1000' 30 | group: '1000' 31 | 32 | # LABELS ###################################################################### 33 | - name: 'Adding Traefik' 34 | set_fact: 35 | pg_labels: 36 | traefik.enable: 'true' 37 | traefik.port: '{{intport}}' 38 | traefik.frontend.auth.forward.address: '{{gauth}}' 39 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 40 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 41 | traefik.frontend.headers.SSLRedirect: 'true' 42 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 43 | traefik.frontend.headers.STSPreload: 'true' 44 | traefik.frontend.headers.STSSeconds: '315360000' 45 | traefik.frontend.headers.browserXSSFilter: 'true' 46 | traefik.frontend.headers.contentTypeNosniff: 'true' 47 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 48 | traefik.frontend.headers.forceSTSHeader: 'true' 49 | 50 | - name: 'Setting PG Volumes' 51 | set_fact: 52 | pg_volumes: 53 | - '/opt/appdata/pgui/index.php:/var/www/html/index.php' 54 | - '/var/plexguide:/plexguide' 55 | - '/opt/appdata/plexguide:/log' 56 | 57 | - name: 'Setting PG ENV' 58 | set_fact: 59 | pg_env: 60 | PUID: '1000' 61 | PGID: '1000' 62 | 63 | # MAIN DEPLOYMENT ############################################################# 64 | - name: 'Deploying {{pgrole}}' 65 | docker_container: 66 | name: '{{pgrole}}' 67 | image: '{{image}}' 68 | pull: yes 69 | published_ports: 70 | - '{{ports.stdout}}{{extport}}:{{intport}}' 71 | volumes: '{{pg_volumes}}' 72 | env: '{{pg_env}}' 73 | restart_policy: unless-stopped 74 | networks: 75 | - name: plexguide 76 | aliases: 77 | - '{{pgrole}}' 78 | state: started 79 | labels: '{{pg_labels}}' 80 | -------------------------------------------------------------------------------- /apps/plex.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Author(s): Admin9705 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - hosts: localhost 10 | gather_facts: false 11 | tasks: 12 | # FACTS ####################################################################### 13 | - name: 'Set Known Facts' 14 | set_fact: 15 | pgrole: 'plex' 16 | intport: '32400/tcp' 17 | extport: '32400' 18 | intport2: '3005/tcp' 19 | extport2: '3005' 20 | intport3: '8324/tcp' 21 | extport3: '8324' 22 | intport4: '32410/udp' 23 | extport4: '32410' 24 | intport5: '32412/udp' 25 | extport5: '32412' 26 | intport6: '32413/udp' 27 | extport6: '32413' 28 | intport7: '32414/udp' 29 | extport7: '32414' 30 | intport8: '33400/tcp' 31 | extport8: '33400' 32 | intport9: '33443/tcp' 33 | extport9: '33443' 34 | image: 'plexinc/pms-docker:latest' 35 | 36 | # CORE (MANDATORY) ############################################################ 37 | - name: 'Including cron job' 38 | include_tasks: '/opt/coreapps/apps/_core.yml' 39 | 40 | # FACTS ####################################################################### 41 | - name: 'Plex Server Network Type' 42 | shell: 'cat /var/plexguide/plex.server' 43 | register: servertype 44 | 45 | - name: Register Claim Number 46 | shell: 'cat /var/plexguide/plex.claim' 47 | register: claim 48 | when: servertype.stdout == "remote" 49 | 50 | # CORE (MANDATORY) ############################################################ 51 | - name: 'Including cron job' 52 | include_tasks: '/opt/coreapps/apps/_core.yml' 53 | 54 | ######################################### FOR BOTH 55 | - name: 'Set Default Labels' 56 | set_fact: 57 | default_labels: 58 | traefik.enable: 'true' 59 | traefik.port: '{{intport}}' 60 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 61 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 62 | traefik.frontend.headers.SSLRedirect: 'true' 63 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 64 | traefik.frontend.headers.STSPreload: 'true' 65 | traefik.frontend.headers.STSSeconds: '315360000' 66 | traefik.frontend.headers.browserXSSFilter: 'true' 67 | traefik.frontend.headers.contentTypeNosniff: 'true' 68 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 69 | traefik.frontend.headers.forceSTSHeader: 'true' 70 | 71 | - name: 'Set Default Volume - {{extension.stdout}}' 72 | set_fact: 73 | default_volumes: 74 | - '/etc/localtime:/etc/localtime:ro' 75 | - '{{path.stdout}}:{{path.stdout}}' 76 | - '/mnt:/mnt' 77 | - '/opt/appdata/{{pgrole}}/database:/config' 78 | - '/tmp:/tmp' 79 | - '/opt/transcodes:/transcode' 80 | - '/dev/shm:/ram_transcode' 81 | 82 | - name: 'Establish Key Variables' 83 | set_fact: 84 | default_env: 85 | UID: '1000' 86 | GID: '1000' 87 | 88 | - name: Check Preferences.xml exists 89 | stat: 90 | path: '/opt/appdata/plex/database/Library/Application Support/Plex Media Server/Preferences.xml' 91 | register: plex_prefs 92 | 93 | ############### This is needed because on a fresh installaions the value is missing and is defaulted to 1 Security perfered 94 | - name: secureConnections is missing 95 | xml: 96 | path: '/opt/appdata/plex/database/Library/Application Support/Plex Media Server/Preferences.xml' 97 | xpath: /Preferences/@secureConnections 98 | count: yes 99 | register: secure_hits 100 | when: 101 | - plex_prefs.stat.exists 102 | 103 | ############### This is needed because on a fresh installaions the value is missing and is defaulted to 1 Security perfered 104 | - name: Add secureConnections if missing 105 | xml: 106 | path: '/opt/appdata/plex/database/Library/Application Support/Plex Media Server/Preferences.xml' 107 | xpath: /Preferences 108 | attribute: secureConnections 109 | value: '1' 110 | when: 111 | - plex_prefs.stat.exists 112 | - secure_hits.count == 0 113 | 114 | - name: Read Preferences.xml 115 | xml: 116 | path: '/opt/appdata/plex/database/Library/Application Support/Plex Media Server/Preferences.xml' 117 | xpath: /Preferences 118 | content: attribute 119 | register: plex_pref_content 120 | when: plex_prefs.stat.exists 121 | 122 | - name: Add https to default_label if secureConnection != 2 123 | set_fact: 124 | default_labels: "{{default_labels | combine( {'traefik.protocol': 'https'} )}}" 125 | when: 126 | - plex_prefs.stat.exists 127 | - plex_pref_content.matches[0]['Preferences']['secureConnections'] 128 | 129 | - name: Read customConnections 130 | set_fact: 131 | customConnections: "{{plex_pref_content.matches[0]['Preferences']['customConnections']}}" 132 | when: 133 | - plex_prefs.stat.exists 134 | - plex_pref_content.matches[0]['Preferences']['customConnections'] is defined 135 | 136 | - name: customConnections missing 137 | set_fact: 138 | customConnections: 'http://{{ipaddress.stdout}}:32400, http://plex.{{domain.stdout}}:32400' 139 | when: 140 | - plex_prefs.stat.exists == False 141 | 142 | - name: 'Get Plex Custom URL' 143 | shell: 'echo https://plex.{{domain.stdout}}:443,http://plex.{{domain.stdout}}:80' 144 | register: plex_url 145 | when: servertype.stdout == "remote" 146 | 147 | - debug: msg="Your plex_url is {{ plex_url.stdout }}" 148 | when: servertype.stdout == "remote" 149 | 150 | - set_fact: 151 | plex_advert_ip: 'http://{{ipaddress.stdout}}:32400' 152 | when: servertype.stdout == "remote" 153 | 154 | - set_fact: 155 | plex_advert_ip: '{{plex_url.stdout}}' 156 | when: servertype.stdout == "remote" 157 | 158 | - debug: msg="plex_advert_ip is {{plex_advert_ip}}" 159 | when: servertype.stdout == "remote" 160 | 161 | ########################################## Other 162 | - name: Check /dev/dri exists 163 | stat: 164 | path: '/dev/dri' 165 | register: dev_dri 166 | 167 | - name: Create Transcodes Directory 168 | file: 'path={{item}} state=directory mode=0775 owner=1000 group=1000' 169 | with_items: 170 | - /opt/transcodes 171 | 172 | - name: customConnections FailSafe 173 | set_fact: 174 | customConnections: 'none' 175 | when: customConnections is undefined 176 | 177 | ######################################### DEPLOY PLEX REMOTE (ANSWER 2) 178 | - name: Deploy Plex Container (Remote Edition) 179 | docker_container: 180 | name: plex 181 | image: '{{image}}' 182 | pull: yes 183 | published_ports: 184 | - '{{extport}}:{{intport}}' 185 | - '{{ports.stdout}}{{extport2}}:{{intport2}}' 186 | - '{{ports.stdout}}{{extport3}}:{{intport3}}' 187 | - '{{ports.stdout}}{{extport4}}:{{intport4}}' 188 | - '{{ports.stdout}}{{extport5}}:{{intport5}}' 189 | - '{{ports.stdout}}{{extport6}}:{{intport6}}' 190 | - '{{ports.stdout}}{{extport7}}:{{intport7}}' 191 | - '{{ports.stdout}}{{extport8}}:{{intport8}}' 192 | - '{{extport9}}:{{intport9}}' 193 | env: 194 | PLEX_UID: '1000' 195 | PLEX_GID: '1000' 196 | PLEX_CLAIM: '{{claim.stdout}}' 197 | ADVERTISE_IP: '{{customConnections}}' 198 | purge_networks: yes 199 | networks: 200 | - name: plexguide 201 | aliases: 202 | - plex 203 | volumes: '{{default_volumes}}' 204 | devices: "{{ '/dev/dri:/dev/dri' if dev_dri.stat.exists == True | default(false) else omit }}" 205 | etc_hosts: 206 | { 'analytics.plex.tv': '127.0.0.1', 'metrics.plex.tv': '127.0.0.1' } 207 | restart_policy: unless-stopped 208 | state: started 209 | labels: '{{default_labels}}' 210 | when: servertype.stdout == "remote" 211 | 212 | ######################################### DEPLOY PLEX LOCAL (ANSWER 3) 213 | - name: Deploy Plex Container (Local Edition) 214 | docker_container: 215 | name: plex 216 | image: '{{image}}' 217 | pull: yes 218 | published_ports: 219 | - '32400:32400/tcp' 220 | - '3005:3005/tcp' 221 | - '8324:8324/tcp' 222 | - '32469:32469/tcp' 223 | - '1900:1900/udp' 224 | - '32410:32410/udp' 225 | - '32412:32412/udp' 226 | - '32413:32413/udp' 227 | - '32414:32414/udp' 228 | - '33400:33400/tcp' 229 | - '33443:33443/tcp' 230 | env: 231 | PLEX_UID: '1000' 232 | PLEX_GID: '1000' 233 | ADVERTISE_IP: '{{customConnections}}' 234 | networks: 235 | - name: plexguide 236 | aliases: 237 | - plex 238 | volumes: '{{default_volumes}}' 239 | devices: "{{ '/dev/dri:/dev/dri' if dev_dri.stat.exists == True | default(false) else omit }}" 240 | etc_hosts: 241 | { 'analytics.plex.tv': '127.0.0.1', 'metrics.plex.tv': '127.0.0.1' } 242 | restart_policy: unless-stopped 243 | state: started 244 | labels: '{{default_labels}}' 245 | when: servertype.stdout == "local" 246 | 247 | ###################### Plex WebTools 248 | - name: Check WebTools 249 | stat: 250 | path: '/opt/appdata/plex/database/Library/Application Support/Plex Media Server/Plug-ins/WebTools.bundle' 251 | register: webtools 252 | 253 | - name: Create Basic Directories 254 | file: 'path={{item}} state=directory mode=0775 owner=1000 group=1000' 255 | with_items: 256 | - '/opt/appdata/plex/database/Library/Application Support/Plex Media Server/Plug-ins/WebTools.bundle' 257 | when: 258 | - webtools.stat.exists == False 259 | 260 | - name: Installing WebTools 261 | unarchive: 262 | src: https://github.com/ukdtom/WebTools.bundle/releases/download/3.0.0/WebTools.bundle.zip 263 | dest: /opt/appdata/plex/database/Library/Application Support/Plex Media Server/Plug-ins 264 | keep_newer: no 265 | owner: '1000' 266 | group: '1000' 267 | mode: 0775 268 | copy: no 269 | when: 270 | - webtools.stat.exists == False 271 | 272 | - name: Notify User 273 | pause: 274 | prompt: "\nWebTools Installed! [PRESS ENTER] to Continue" 275 | when: 276 | - webtools.stat.exists == False 277 | 278 | - debug: msg="Final Notes - Remote Plex | IP Address {{ipaddress.stdout}} | Plex Type {{servertype.stdout}} | Token {{claim.stdout}}" 279 | when: servertype.stdout == "remote" 280 | 281 | - debug: msg="Final Notes - Local Plex | IP Address {{ipaddress.stdout}} | Plex Type {{servertype.stdout}}" 282 | when: servertype.stdout == "local" 283 | -------------------------------------------------------------------------------- /apps/portainer.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Author(s): Admin9705 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - hosts: localhost 10 | gather_facts: false 11 | tasks: 12 | # FACTS ####################################################################### 13 | - name: 'Set Known Facts' 14 | set_fact: 15 | pgrole: 'portainer' 16 | intport: '9000' 17 | extport: '9000' 18 | image: 'portainer/portainer-ce:alpine' 19 | # CORE (MANDATORY) ############################################################ 20 | - name: 'Including cron job' 21 | include_tasks: '/opt/coreapps/apps/_core.yml' 22 | 23 | # LABELS ###################################################################### 24 | - name: 'Adding Traefik' 25 | set_fact: 26 | pg_labels: 27 | traefik.enable: 'true' 28 | traefik.port: '{{intport}}' 29 | traefik.frontend.auth.forward.address: '{{gauth}}' 30 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 31 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 32 | traefik.frontend.headers.SSLRedirect: 'true' 33 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 34 | traefik.frontend.headers.STSPreload: 'true' 35 | traefik.frontend.headers.STSSeconds: '315360000' 36 | traefik.frontend.headers.browserXSSFilter: 'true' 37 | traefik.frontend.headers.contentTypeNosniff: 'true' 38 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 39 | traefik.frontend.headers.forceSTSHeader: 'true' 40 | 41 | - name: 'Setting {{pgrole}} Volumes' 42 | set_fact: 43 | pg_volumes: 44 | - '/etc/localtime:/etc/localtime:ro' 45 | - '/opt/appdata/{{pgrole}}:/data' 46 | - '/var/run/docker.sock:/var/run/docker.sock' 47 | 48 | - name: 'Setting {{pgrole}} ENV' 49 | set_fact: 50 | pg_env: 51 | PUID: '1000' 52 | PGID: '1000' 53 | 54 | # MAIN DEPLOYMENT ############################################################# 55 | - name: 'Deploying {{pgrole}}' 56 | docker_container: 57 | name: '{{pgrole}}' 58 | hostname: '{{pgrole}}' 59 | image: '{{image}}' 60 | pull: yes 61 | published_ports: 62 | - '{{ports.stdout}}{{extport}}:{{intport}}' 63 | volumes: '{{pg_volumes}}' 64 | env: '{{pg_env}}' 65 | restart_policy: unless-stopped 66 | networks: 67 | - name: plexguide 68 | aliases: 69 | - '{{pgrole}}' 70 | state: started 71 | labels: '{{pg_labels}}' 72 | -------------------------------------------------------------------------------- /apps/qbittorrent.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Author(s): Admin9705 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - hosts: localhost 10 | gather_facts: false 11 | tasks: 12 | # FACTS ####################################################################### 13 | 14 | - name: 'Set Known Facts' 15 | set_fact: 16 | pgrole: 'qbittorrent' 17 | intport: '8080' 18 | extport: '8083' 19 | intport2: '7889' 20 | extport2: '7889' 21 | image: 'linuxserver/qbittorrent' 22 | 23 | # CORE (MANDATORY) ############################################################# 24 | - name: 'Including cron job' 25 | include_tasks: '/opt/coreapps/apps/_core.yml' 26 | 27 | - name: 'Including folders' 28 | include_tasks: '/opt/coreapps/apps/_downloaders.yml' 29 | 30 | - name: 'Including plugins' 31 | include_tasks: '/opt/coreapps/apps/_plugins.yml' 32 | 33 | # LABELS ###################################################################### 34 | - name: 'Adding Traefik' 35 | set_fact: 36 | pg_labels: 37 | traefik.frontend.auth.forward.address: '{{gauth}}' 38 | traefik.enable: 'true' 39 | traefik.port: '{{intport}}' 40 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 41 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 42 | traefik.frontend.headers.SSLRedirect: 'true' 43 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 44 | traefik.frontend.headers.STSPreload: 'true' 45 | traefik.frontend.headers.STSSeconds: '315360000' 46 | traefik.frontend.headers.browserXSSFilter: 'true' 47 | traefik.frontend.headers.contentTypeNosniff: 'true' 48 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 49 | traefik.frontend.headers.forceSTSHeader: 'true' 50 | 51 | - name: 'Setting PG Volumes' 52 | set_fact: 53 | pg_volumes: 54 | - '/etc/localtime:/etc/localtime:ro' 55 | - '{{path.stdout}}:{{path.stdout}}' 56 | - '/mnt:/mnt' 57 | - '/opt/appdata/{{pgrole}}:/config' 58 | 59 | - name: 'Setting PG ENV' 60 | set_fact: 61 | pg_env: 62 | PUID: '1000' 63 | PGID: '1000' 64 | 65 | # MAIN DEPLOYMENT ############################################################# 66 | - name: 'Checking for existing app data' 67 | stat: 68 | path: '/opt/appdata/{{pgrole}}/qBittorrent/qBittorrent.conf' 69 | register: confcheck 70 | 71 | - name: 'Deploying {{pgrole}}' 72 | docker_container: 73 | name: '{{pgrole}}' 74 | image: '{{image}}' 75 | pull: yes 76 | published_ports: 77 | - '{{ports.stdout}}{{extport}}:{{intport}}' 78 | - '{{extport2}}:{{intport2}}' 79 | volumes: '{{pg_volumes}}' 80 | env: '{{pg_env}}' 81 | restart_policy: unless-stopped 82 | networks: 83 | - name: plexguide 84 | aliases: 85 | - '{{pgrole}}' 86 | state: started 87 | labels: '{{pg_labels}}' 88 | 89 | # CONFIGURATION #################################################### 90 | - name: 'Waiting for {{pgrole}} to initialize' 91 | wait_for: 92 | path: '/opt/appdata/{{pgrole}}/qBittorrent/qBittorrent.conf' 93 | state: present 94 | timeout: 15 95 | delay: 5 96 | 97 | - name: 'Stopping {{pgrole}}' 98 | docker_container: 99 | name: '{{pgrole}}' 100 | state: stopped 101 | 102 | - name: Set torrent port 103 | ini_file: 104 | path: '/opt/appdata/{{pgrole}}/qBittorrent/qBittorrent.conf' 105 | section: Preferences 106 | option: Connection\PortRangeMin 107 | value: '7889' 108 | state: present 109 | 110 | - name: Set SavePath 111 | ini_file: 112 | path: '/opt/appdata/{{pgrole}}/qBittorrent/qBittorrent.conf' 113 | section: Preferences 114 | option: Downloads\SavePath 115 | value: '{{path.stdout}}/downloads/{{pgrole}}' 116 | state: present 117 | 118 | - name: Set TempPath 119 | ini_file: 120 | path: '/opt/appdata/{{pgrole}}/qBittorrent/qBittorrent.conf' 121 | section: Preferences 122 | option: Downloads\TempPath 123 | value: '{{path.stdout}}/incomplete/{{pgrole}}' 124 | state: present 125 | 126 | - name: Set TempPathEnabled 127 | ini_file: 128 | path: '/opt/appdata/{{pgrole}}/qBittorrent/qBittorrent.conf' 129 | section: Preferences 130 | option: Downloads\TempPathEnabled 131 | value: True 132 | state: present 133 | 134 | # FIRST TIME CONFIGURATION #################################################### 135 | - name: 'Configuring {{pgrole}} for first time use' 136 | block: 137 | - name: Enable AutoRun 138 | ini_file: 139 | path: '/opt/appdata/{{pgrole}}/qBittorrent/qBittorrent.conf' 140 | section: AutoRun 141 | option: enabled 142 | value: True 143 | state: present 144 | 145 | - name: Enable Auto UnRar 146 | ini_file: 147 | path: '/opt/appdata/{{pgrole}}/qBittorrent/qBittorrent.conf' 148 | section: AutoRun 149 | option: program 150 | value: '/usr/bin/unrar x -r \"%F/.\" \"%F/\"' 151 | state: present 152 | 153 | - name: Disable DHT 154 | ini_file: 155 | path: '/opt/appdata/{{pgrole}}/qBittorrent/qBittorrent.conf' 156 | section: Preferences 157 | option: Bittorrent\DHT 158 | value: false 159 | state: present 160 | 161 | - name: Disable PeX 162 | ini_file: 163 | path: '/opt/appdata/{{pgrole}}/qBittorrent/qBittorrent.conf' 164 | section: Preferences 165 | option: Bittorrent\PeX 166 | value: false 167 | state: present 168 | 169 | - name: Disable LSD 170 | ini_file: 171 | path: '/opt/appdata/{{pgrole}}/qBittorrent/qBittorrent.conf' 172 | section: Preferences 173 | option: Bittorrent\LSD 174 | value: false 175 | state: present 176 | 177 | - name: Enable Encryption 178 | ini_file: 179 | path: '/opt/appdata/{{pgrole}}/qBittorrent/qBittorrent.conf' 180 | section: Preferences 181 | option: Bittorrent\Encryption 182 | value: 1 183 | state: present 184 | 185 | - name: Don't use incomplete extension 186 | ini_file: 187 | path: '/opt/appdata/{{pgrole}}/qBittorrent/qBittorrent.conf' 188 | section: Preferences 189 | option: Downloads\UseIncompleteExtension 190 | value: false 191 | state: present 192 | 193 | - name: Ignore slow torrents 194 | ini_file: 195 | path: '/opt/appdata/{{pgrole}}/qBittorrent/qBittorrent.conf' 196 | section: Preferences 197 | option: Queueing\IgnoreSlowTorrents 198 | value: True 199 | state: present 200 | 201 | - name: Set MaxActiveDownloads 202 | ini_file: 203 | path: '/opt/appdata/{{pgrole}}/qBittorrent/qBittorrent.conf' 204 | section: Preferences 205 | option: Queueing\MaxActiveDownloads 206 | value: 10 207 | state: present 208 | 209 | - name: Set MaxActiveTorrents 210 | ini_file: 211 | path: '/opt/appdata/{{pgrole}}/qBittorrent/qBittorrent.conf' 212 | section: Preferences 213 | option: Queueing\MaxActiveTorrents 214 | value: 100 215 | state: present 216 | 217 | - name: Set MaxActiveUploads 218 | ini_file: 219 | path: '/opt/appdata/{{pgrole}}/qBittorrent/qBittorrent.conf' 220 | section: Preferences 221 | option: Queueing\MaxActiveUploads 222 | value: 100 223 | state: present 224 | 225 | - name: Set GlobalMaxSeedingMinutes 226 | ini_file: 227 | path: '/opt/appdata/{{pgrole}}/qBittorrent/qBittorrent.conf' 228 | section: BitTorrent 229 | option: Session\GlobalMaxSeedingMinutes 230 | value: 20160 231 | state: present 232 | 233 | - name: Set MaxRatio 234 | ini_file: 235 | path: '/opt/appdata/{{pgrole}}/qBittorrent/qBittorrent.conf' 236 | section: Preferences 237 | option: Bittorrent\MaxRatio 238 | value: 1 239 | state: present 240 | 241 | - name: pause on MaxRatioAction 242 | ini_file: 243 | path: '/opt/appdata/{{pgrole}}/qBittorrent/qBittorrent.conf' 244 | section: Preferences 245 | option: Bittorrent\MaxRatioAction 246 | value: 1 247 | state: present 248 | 249 | - name: Disable csrf 250 | ini_file: 251 | path: '/opt/appdata/{{pgrole}}/qBittorrent/qBittorrent.conf' 252 | section: Preferences 253 | option: WebUI\CSRFProtection 254 | value: false 255 | force: yes 256 | state: present 257 | 258 | - name: Disable HostHeaderValidation 259 | ini_file: 260 | path: '/opt/appdata/{{pgrole}}/qBittorrent/qBittorrent.conf' 261 | section: Preferences 262 | option: WebUI\HostHeaderValidation 263 | value: false 264 | force: yes 265 | state: present 266 | 267 | - name: Disable ClickjackingProtection 268 | ini_file: 269 | path: '/opt/appdata/{{pgrole}}/qBittorrent/qBittorrent.conf' 270 | section: Preferences 271 | option: WebUI\ClickjackingProtection 272 | value: false 273 | force: yes 274 | state: present 275 | 276 | - name: Set ServerDomains 277 | ini_file: 278 | path: '/opt/appdata/{{pgrole}}/qBittorrent/qBittorrent.conf' 279 | section: Preferences 280 | option: WebUI\ServerDomains 281 | value: '*' 282 | force: yes 283 | state: present 284 | 285 | - name: Set Address 286 | ini_file: 287 | path: '/opt/appdata/{{pgrole}}/qBittorrent/qBittorrent.conf' 288 | section: Preferences 289 | option: WebUI\Address 290 | value: '*' 291 | force: yes 292 | state: present 293 | 294 | when: not confcheck.stat.exists 295 | 296 | - name: Restart {{pgrole}} 297 | docker_container: 298 | name: '{{pgrole}}' 299 | state: started 300 | -------------------------------------------------------------------------------- /apps/radarr.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Author(s): Admin9705 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - hosts: localhost 10 | gather_facts: false 11 | tasks: 12 | # FACTS ####################################################################### 13 | 14 | - name: 'Set Known Facts' 15 | set_fact: 16 | pgrole: 'radarr' 17 | intport: '7878' 18 | extport: '7878' 19 | image: 'linuxserver/radarr:nightly' 20 | 21 | # CORE (MANDATORY) ############################################################ 22 | - name: 'Including cron job' 23 | include_tasks: '/opt/coreapps/apps/_core.yml' 24 | 25 | - name: 'Including plugins' 26 | include_tasks: '/opt/coreapps/apps/_plugins.yml' 27 | 28 | # LABELS ###################################################################### 29 | - name: 'Adding Traefik' 30 | set_fact: 31 | pg_labels: 32 | traefik.enable: 'true' 33 | traefik.port: '{{intport}}' 34 | traefik.frontend.auth.forward.address: '{{gauth}}' 35 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 36 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 37 | traefik.frontend.headers.SSLRedirect: 'true' 38 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 39 | traefik.frontend.headers.STSPreload: 'true' 40 | traefik.frontend.headers.STSSeconds: '315360000' 41 | traefik.frontend.headers.browserXSSFilter: 'true' 42 | traefik.frontend.headers.contentTypeNosniff: 'true' 43 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 44 | traefik.frontend.headers.forceSTSHeader: 'true' 45 | 46 | - name: 'Setting {{pgrole}} Volumes' 47 | set_fact: 48 | pg_volumes: 49 | - '{{path.stdout}}:{{path.stdout}}' 50 | - '/opt/appdata/{{pgrole}}:/config' 51 | - '/opt/appdata/{{pgrole}}/mp4_automator:/config_mp4_automator' 52 | 53 | - name: 'Setting {{pgrole}} ENV' 54 | set_fact: 55 | pg_env: 56 | PUID: '1000' 57 | PGID: '1000' 58 | 59 | # MAIN DEPLOYMENT ############################################################# 60 | 61 | - name: 'Deploying {{pgrole}}' 62 | docker_container: 63 | name: '{{pgrole}}' 64 | image: '{{image}}' 65 | pull: yes 66 | published_ports: 67 | - '{{ports.stdout}}{{extport}}:{{intport}}' 68 | volumes: '{{pg_volumes}}' 69 | env: '{{pg_env}}' 70 | restart_policy: unless-stopped 71 | networks: 72 | - name: plexguide 73 | aliases: 74 | - '{{pgrole}}' 75 | state: started 76 | labels: '{{pg_labels}}' 77 | 78 | - name: 'Checking for existing app data' 79 | stat: 80 | path: /opt/appdata/{{pgrole}}/config.xml 81 | register: confcheck 82 | 83 | - name: 'Update {{pgrole}} for first time use' 84 | block: 85 | - pause: 86 | prompt: "Wait for {{pgrole}} start up" 87 | seconds: 5 88 | -------------------------------------------------------------------------------- /apps/radarr4k.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Author(s): Admin9705 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - hosts: localhost 10 | gather_facts: false 11 | tasks: 12 | # CORE (MANDATORY) DO NOT CHANGE ########################################### 13 | 14 | - name: 'Set Known Facts' 15 | set_fact: 16 | pgrole: 'radarr4k' 17 | intport: '7878' 18 | extport: '7874' 19 | image: 'linuxserver/radarr:nightly' 20 | 21 | # CORE (MANDATORY) ############################################################ 22 | - name: 'Including cron job' 23 | include_tasks: '/opt/coreapps/apps/_core.yml' 24 | 25 | - name: 'Including plugins' 26 | include_tasks: '/opt/coreapps/apps/_plugins.yml' 27 | 28 | # LABELS ###################################################################### 29 | - name: 'Adding Traefik' 30 | set_fact: 31 | pg_labels: 32 | traefik.enable: 'true' 33 | traefik.port: '{{intport}}' 34 | traefik.frontend.auth.forward.address: '{{gauth}}' 35 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 36 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 37 | traefik.frontend.headers.SSLRedirect: 'true' 38 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 39 | traefik.frontend.headers.STSPreload: 'true' 40 | traefik.frontend.headers.STSSeconds: '315360000' 41 | traefik.frontend.headers.browserXSSFilter: 'true' 42 | traefik.frontend.headers.contentTypeNosniff: 'true' 43 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 44 | traefik.frontend.headers.forceSTSHeader: 'true' 45 | 46 | - name: 'Setting {{pgrole}} Volumes' 47 | set_fact: 48 | pg_volumes: 49 | - '{{path.stdout}}:{{path.stdout}}' 50 | - '/opt/appdata/{{pgrole}}:/config' 51 | - '/opt/appdata/{{pgrole}}/mp4_automator:/config_mp4_automator' 52 | 53 | - name: 'Setting {{pgrole}} ENV' 54 | set_fact: 55 | pg_env: 56 | PUID: '1000' 57 | PGID: '1000' 58 | 59 | # MAIN DEPLOYMENT ############################################################# 60 | 61 | - name: 'Deploying {{pgrole}}' 62 | docker_container: 63 | name: '{{pgrole}}' 64 | image: '{{image}}' 65 | pull: yes 66 | published_ports: 67 | - '{{ports.stdout}}{{extport}}:{{intport}}' 68 | volumes: '{{pg_volumes}}' 69 | env: '{{pg_env}}' 70 | restart_policy: unless-stopped 71 | networks: 72 | - name: plexguide 73 | aliases: 74 | - '{{pgrole}}' 75 | state: started 76 | labels: '{{pg_labels}}' 77 | 78 | - name: 'Checking for existing app data' 79 | stat: 80 | path: /opt/appdata/{{pgrole}}/config.xml 81 | register: confcheck 82 | 83 | - name: 'Update {{pgrole}} for first time use' 84 | block: 85 | - pause: 86 | prompt: "Wait for {{pgrole}} start up" 87 | seconds: 5 88 | 89 | - name: 'update owner rights for {{pgrole}}' 90 | shell: 'docker exec {{pgrole}} chown -cR abc:abc /opt/radarr/' 91 | 92 | - name: 'update permission errors for {{pgrole}}' 93 | shell: 'docker exec {{pgrole}} chmod -cR 775 /opt/radarr' 94 | 95 | when: confcheck.stat.exists 96 | -------------------------------------------------------------------------------- /apps/radarrhdr.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Author(s): Admin9705 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - hosts: localhost 10 | gather_facts: false 11 | tasks: 12 | # CORE (MANDATORY) DO NOT CHANGE ########################################### 13 | 14 | - name: 'Set Known Facts' 15 | set_fact: 16 | pgrole: 'radarrhdr' 17 | intport: '7878' 18 | extport: '7877' 19 | image: 'linuxserver/radarr:nightly' 20 | 21 | # CORE (MANDATORY) ############################################################ 22 | - name: 'Including cron job' 23 | include_tasks: '/opt/coreapps/apps/_core.yml' 24 | 25 | - name: 'Including plugins' 26 | include_tasks: '/opt/coreapps/apps/_plugins.yml' 27 | 28 | # LABELS ###################################################################### 29 | - name: 'Adding Traefik' 30 | set_fact: 31 | pg_labels: 32 | traefik.enable: 'true' 33 | traefik.port: '{{intport}}' 34 | traefik.frontend.auth.forward.address: '{{gauth}}' 35 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 36 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 37 | traefik.frontend.headers.SSLRedirect: 'true' 38 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 39 | traefik.frontend.headers.STSPreload: 'true' 40 | traefik.frontend.headers.STSSeconds: '315360000' 41 | traefik.frontend.headers.browserXSSFilter: 'true' 42 | traefik.frontend.headers.contentTypeNosniff: 'true' 43 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 44 | traefik.frontend.headers.forceSTSHeader: 'true' 45 | 46 | - name: 'Setting {{pgrole}} Volumes' 47 | set_fact: 48 | pg_volumes: 49 | - '{{path.stdout}}:{{path.stdout}}' 50 | - '/opt/appdata/{{pgrole}}:/config' 51 | - '/opt/appdata/{{pgrole}}/mp4_automator:/config_mp4_automator' 52 | 53 | - name: 'Setting {{pgrole}} ENV' 54 | set_fact: 55 | pg_env: 56 | PUID: '1000' 57 | PGID: '1000' 58 | 59 | # MAIN DEPLOYMENT ############################################################# 60 | 61 | - name: 'Deploying {{pgrole}}' 62 | docker_container: 63 | name: '{{pgrole}}' 64 | image: '{{image}}' 65 | pull: yes 66 | published_ports: 67 | - '{{ports.stdout}}{{extport}}:{{intport}}' 68 | volumes: '{{pg_volumes}}' 69 | env: '{{pg_env}}' 70 | restart_policy: unless-stopped 71 | networks: 72 | - name: plexguide 73 | aliases: 74 | - '{{pgrole}}' 75 | state: started 76 | labels: '{{pg_labels}}' 77 | 78 | - name: 'Checking for existing app data' 79 | stat: 80 | path: /opt/appdata/{{pgrole}}/config.xml 81 | register: confcheck 82 | 83 | - name: 'Update {{pgrole}} for first time use' 84 | block: 85 | - pause: 86 | prompt: "Wait for {{pgrole}} start up" 87 | seconds: 5 88 | 89 | - name: 'update owner rights for {{pgrole}}' 90 | shell: 'docker exec {{pgrole}} chown -cR abc:abc /opt/radarr/' 91 | 92 | - name: 'update permission errors for {{pgrole}}' 93 | shell: 'docker exec {{pgrole}} chmod -cR 775 /opt/radarr' 94 | 95 | when: confcheck.stat.exists 96 | -------------------------------------------------------------------------------- /apps/rutorrent.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Author(s): Admin9705 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - hosts: localhost 10 | gather_facts: false 11 | tasks: 12 | # FACTS ####################################################################### 13 | - name: 'Set Known Facts' 14 | set_fact: 15 | pgrole: 'rutorrent' 16 | intport: '80' 17 | extport: '8999' 18 | intport2: '5000' 19 | extport2: '5000' 20 | intport3: '51413' 21 | extport3: '51413' 22 | image: 'linuxserver/rutorrent' 23 | 24 | # CORE (MANDATORY) ############################################################ 25 | - name: 'Including cron job' 26 | include_tasks: '/opt/coreapps/apps/_core.yml' 27 | 28 | - name: 'Including folders' 29 | include_tasks: '/opt/coreapps/apps/_downloaders.yml' 30 | 31 | # Tasks #################################################### 32 | - name: Delete stock themes 33 | shell: 'path={{item}} state=absent' 34 | with_items: 35 | - '/opt/appdata/{{pgrole}}/plugins/mobile' 36 | - '/opt/appdata/{{pgrole}}/plugins/theme/themes/FlatUI_Dark' 37 | 38 | - name: 'Including plugins' 39 | include_tasks: '/opt/coreapps/apps/_plugins.yml' 40 | 41 | # LABELS ###################################################################### 42 | - name: 'Adding Traefik' 43 | set_fact: 44 | pg_labels: 45 | traefik.enable: 'true' 46 | traefik.port: '{{intport}}' 47 | traefik.frontend.auth.forward.address: '{{gauth}}' 48 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 49 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 50 | traefik.frontend.headers.SSLRedirect: 'true' 51 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 52 | traefik.frontend.headers.STSPreload: 'true' 53 | traefik.frontend.headers.STSSeconds: '315360000' 54 | traefik.frontend.headers.browserXSSFilter: 'true' 55 | traefik.frontend.headers.contentTypeNosniff: 'true' 56 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 57 | traefik.frontend.headers.forceSTSHeader: 'true' 58 | 59 | - name: 'Setting {{pgrole}} Volumes' 60 | set_fact: 61 | pg_volumes: 62 | - '{{path.stdout}}:{{path.stdout}}' 63 | - '/opt/appdata/{{pgrole}}:/config' 64 | - '/opt/appdata/{{pgrole}}/sock:/run/php' 65 | 66 | - name: 'Setting {{pgrole}} ENV' 67 | set_fact: 68 | pg_env: 69 | PUID: '1000' 70 | PGID: '1000' 71 | 72 | # MAIN DEPLOYMENT ############################################################# 73 | - name: 'Deploying {{pgrole}}' 74 | docker_container: 75 | name: '{{pgrole}}' 76 | image: '{{image}}' 77 | pull: yes 78 | published_ports: 79 | - '{{ports.stdout}}{{extport}}:{{intport}}' 80 | - '{{ports.stdout}}{{extport2}}:{{intport2}}' 81 | - '{{extport3}}:{{intport3}}' 82 | volumes: '{{pg_volumes}}' 83 | env: '{{pg_env}}' 84 | restart_policy: unless-stopped 85 | networks: 86 | - name: plexguide 87 | aliases: 88 | - '{{pgrole}}' 89 | state: started 90 | purge_networks: yes 91 | stop_timeout: '240' 92 | labels: '{{pg_labels}}' 93 | 94 | # CONFIGURATION #################################################### 95 | - name: 'Waiting for {{pgrole}} to initialize' 96 | wait_for: 97 | path: '/opt/appdata/{{pgrole}}/rtorrent/rtorrent.rc' 98 | state: present 99 | msg: rtorrent.rc creation failed 100 | 101 | - name: 'Stopping {{pgrole}}' 102 | docker_container: 103 | name: '{{pgrole}}' 104 | state: stopped 105 | 106 | - name: 'Including Main Task' 107 | include_tasks: '/opt/coreapps/apps/templates/rutorrent/tasks/main.yml' 108 | 109 | # This is needed for rutorrent b/c it's weird. 110 | - name: 'Setting ownership on appdata recursivley (this can take a while!)' 111 | shell: 'chown -cR 1000:1000 /opt/appdata/{{pgrole}}' 112 | 113 | - name: 'Setting permissions on appdata recursivley (this can take a while!)' 114 | shell: 'chmod -cR 775 /opt/appdata/{{pgrole}}' 115 | 116 | # FIRST TIME CONFIGURATION #################################################### 117 | 118 | - name: Restart Docker Container 119 | docker_container: 120 | name: '{{pgrole}}' 121 | state: started 122 | -------------------------------------------------------------------------------- /apps/sabnzbd.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Author(s): Admin9705 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - hosts: localhost 10 | gather_facts: false 11 | tasks: 12 | # FACTS ####################################################################### 13 | 14 | - name: 'Set Known Facts' 15 | set_fact: 16 | pgrole: 'sabnzbd' 17 | intport: '8080' 18 | extport: '8080' 19 | image: 'linuxserver/sabnzbd:latest' 20 | 21 | # CORE (MANDATORY) ############################################################ 22 | - name: 'Including cron job' 23 | include_tasks: '/opt/coreapps/apps/_core.yml' 24 | 25 | - name: 'Including folders' 26 | include_tasks: '/opt/coreapps/apps/_downloaders.yml' 27 | 28 | - name: Create nzb folder 29 | file: 'path={{item}} state=directory mode=0775 owner=1000 group=1000' 30 | with_items: 31 | - '{{path.stdout}}/nzb' 32 | - '{{path.stdout}}/nzb/watch' 33 | 34 | - name: 'Including plugins' 35 | include_tasks: '/opt/coreapps/apps/_plugins.yml' 36 | 37 | - name: 'Checking for existing app data' 38 | stat: 39 | path: /opt/appdata/{{pgrole}}/sabnzbd.ini 40 | register: inicheck 41 | 42 | # LABELS ###################################################################### 43 | - name: 'Adding Traefik' 44 | set_fact: 45 | pg_labels: 46 | traefik.enable: 'true' 47 | traefik.port: '{{intport}}' 48 | traefik.frontend.auth.forward.address: '{{gauth}}' 49 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 50 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 51 | traefik.frontend.headers.SSLRedirect: 'true' 52 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 53 | traefik.frontend.headers.STSPreload: 'true' 54 | traefik.frontend.headers.STSSeconds: '315360000' 55 | traefik.frontend.headers.browserXSSFilter: 'true' 56 | traefik.frontend.headers.contentTypeNosniff: 'true' 57 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 58 | traefik.frontend.headers.forceSTSHeader: 'true' 59 | 60 | - name: 'Setting {{pgrole}} Volumes' 61 | set_fact: 62 | pg_volumes: 63 | - '{{path.stdout}}:{{path.stdout}}' 64 | - '/opt/appdata/{{pgrole}}:/config' 65 | 66 | - name: 'Setting {{pgrole}} ENV' 67 | set_fact: 68 | pg_env: 69 | PUID: '1000' 70 | PGID: '1000' 71 | 72 | # MAIN DEPLOYMENT ############################################################# 73 | 74 | - name: 'Deploying {{pgrole}}' 75 | docker_container: 76 | name: '{{pgrole}}' 77 | image: '{{image}}' 78 | pull: yes 79 | published_ports: 80 | - '{{ports.stdout}}{{extport}}:{{intport}}' 81 | volumes: '{{pg_volumes}}' 82 | env: '{{pg_env}}' 83 | restart_policy: unless-stopped 84 | networks: 85 | - name: plexguide 86 | aliases: 87 | - '{{pgrole}}' 88 | state: started 89 | labels: '{{pg_labels}}' 90 | 91 | # CONFIGURATION ########################################################### 92 | - name: 'Waiting for {{pgrole}} to initialize' 93 | wait_for: 94 | path: '/opt/appdata/{{pgrole}}/sabnzbd.ini' 95 | state: present 96 | delay: 5 97 | 98 | - name: 'Stopping {{pgrole}}' 99 | docker_container: 100 | name: '{{pgrole}}' 101 | state: stopped 102 | 103 | - name: Set download_dir when incomplete is undefined 104 | ini_file: 105 | path: '/opt/appdata/{{pgrole}}/sabnzbd.ini' 106 | section: misc 107 | option: download_dir 108 | value: '{{path.stdout}}/incomplete/{{pgrole}}' 109 | state: present 110 | 111 | - name: Set complete_dir 112 | ini_file: 113 | path: '/opt/appdata/{{pgrole}}/sabnzbd.ini' 114 | section: misc 115 | option: complete_dir 116 | value: '{{path.stdout}}/downloads/{{pgrole}}' 117 | state: present 118 | 119 | - name: Set nzb watch location 120 | ini_file: 121 | path: '/opt/appdata/{{pgrole}}/sabnzbd.ini' 122 | section: misc 123 | option: dirscan_dir 124 | value: '{{path.stdout}}/nzb/watch' 125 | state: present 126 | 127 | - name: Set nzb backup location 128 | ini_file: 129 | path: '/opt/appdata/{{pgrole}}/sabnzbd.ini' 130 | section: misc 131 | option: nzb_backup_dir 132 | value: '{{path.stdout}}/nzb' 133 | state: present 134 | 135 | - name: set script_dir 136 | ini_file: 137 | path: '/opt/appdata/{{pgrole}}/sabnzbd.ini' 138 | section: misc 139 | option: script_dir 140 | value: scripts 141 | state: present 142 | 143 | # FIRST TIME CONFIGURATION ########################################################### 144 | - name: 'Configuring {{pgrole}} for first time use' 145 | block: 146 | - name: Set host_whitelist 147 | ini_file: 148 | path: '/opt/appdata/{{pgrole}}/sabnzbd.ini' 149 | section: misc 150 | option: host_whitelist 151 | value: 'sabnzbd.{{domain.stdout}},' 152 | state: present 153 | 154 | - name: Set direct_unpack 155 | ini_file: 156 | path: '/opt/appdata/{{pgrole}}/sabnzbd.ini' 157 | section: misc 158 | option: direct_unpack 159 | value: 1 160 | state: present 161 | 162 | - name: Set ignore_samples 163 | ini_file: 164 | path: '/opt/appdata/{{pgrole}}/sabnzbd.ini' 165 | section: misc 166 | option: ignore_samples 167 | value: 1 168 | state: present 169 | 170 | - name: Set max logging lines 171 | ini_file: 172 | path: '/opt/appdata/{{pgrole}}/sabnzbd.ini' 173 | section: misc 174 | option: max_log_size 175 | value: 524 176 | state: present 177 | 178 | - name: Set max logging days 179 | ini_file: 180 | path: '/opt/appdata/{{pgrole}}/sabnzbd.ini' 181 | section: misc 182 | option: log_backups 183 | value: 1 184 | state: present 185 | 186 | - name: set unwanted_extensions 187 | ini_file: 188 | path: '/opt/appdata/{{pgrole}}/sabnzbd.ini' 189 | section: misc 190 | option: unwanted_extensions 191 | value: exe, com, bat, sh, iso, m2ts, mt2s 192 | state: present 193 | 194 | - name: set cleanup_list 195 | ini_file: 196 | path: '/opt/appdata/{{pgrole}}/sabnzbd.ini' 197 | section: misc 198 | option: cleanup_list 199 | value: nfo, exe, com, bat, txt, doc, xls, xlxs, docx, doc, jpg, jeg, gif, png 200 | state: present 201 | 202 | - name: set Cache Limit to 4G 203 | ini_file: 204 | path: '/opt/appdata/{{pgrole}}/sabnzbd.ini' 205 | section: misc 206 | option: cache_limit 207 | value: 4G 208 | state: present 209 | 210 | - name: set action_on_unwanted_extensions 211 | ini_file: 212 | path: '/opt/appdata/{{pgrole}}/sabnzbd.ini' 213 | section: misc 214 | option: action_on_unwanted_extensions 215 | value: 2 216 | state: present 217 | 218 | - name: set pause_on_pwrar - aborts encrypted rar rather than pausing 219 | ini_file: 220 | path: '/opt/appdata/{{pgrole}}/sabnzbd.ini' 221 | section: misc 222 | option: pause_on_pwrar 223 | value: 2 224 | state: present 225 | 226 | - name: set new_nzb_on_failure - try a new nzb if it fails 227 | ini_file: 228 | path: '/opt/appdata/{{pgrole}}/sabnzbd.ini' 229 | section: misc 230 | option: new_nzb_on_failure 231 | value: 1 232 | state: present 233 | 234 | - name: set flat_unpack 235 | ini_file: 236 | path: '/opt/appdata/{{pgrole}}/sabnzbd.ini' 237 | section: misc 238 | option: flat_unpack 239 | value: 1 240 | state: present 241 | 242 | - name: set download_free 243 | ini_file: 244 | path: '/opt/appdata/{{pgrole}}/sabnzbd.ini' 245 | section: misc 246 | option: download_free 247 | value: 25G 248 | state: present 249 | when: not inicheck.stat.exists 250 | 251 | - name: Restart {{pgrole}} 252 | docker_container: 253 | name: '{{pgrole}}' 254 | state: started 255 | -------------------------------------------------------------------------------- /apps/sonarr.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Author(s): Admin9705 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - hosts: localhost 10 | gather_facts: false 11 | tasks: 12 | # FACTS ####################################################################### 13 | 14 | - name: 'Set Known Facts' 15 | set_fact: 16 | pgrole: 'sonarr' 17 | intport: '8989' 18 | extport: '8989' 19 | image: 'linuxserver/sonarr:preview' 20 | 21 | # CORE (MANDATORY) ############################################################ 22 | - name: 'Including cron job' 23 | include_tasks: '/opt/coreapps/apps/_core.yml' 24 | 25 | - name: 'Including plugins' 26 | include_tasks: '/opt/coreapps/apps/_plugins.yml' 27 | 28 | # LABELS ###################################################################### 29 | - name: 'Adding Traefik' 30 | set_fact: 31 | pg_labels: 32 | traefik.enable: 'true' 33 | traefik.port: '{{intport}}' 34 | traefik.frontend.auth.forward.address: '{{gauth}}' 35 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 36 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 37 | traefik.frontend.headers.SSLRedirect: 'true' 38 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 39 | traefik.frontend.headers.STSPreload: 'true' 40 | traefik.frontend.headers.STSSeconds: '315360000' 41 | traefik.frontend.headers.browserXSSFilter: 'true' 42 | traefik.frontend.headers.contentTypeNosniff: 'true' 43 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 44 | traefik.frontend.headers.forceSTSHeader: 'true' 45 | 46 | - name: 'Setting {{pgrole}} Volumes' 47 | set_fact: 48 | pg_volumes: 49 | - '{{path.stdout}}:{{path.stdout}}' 50 | - '/opt/appdata/{{pgrole}}:/config' 51 | - '/opt/appdata/{{pgrole}}/mp4_automator:/config_mp4_automator' 52 | 53 | - name: 'Setting {{pgrole}} ENV' 54 | set_fact: 55 | pg_env: 56 | PUID: '1000' 57 | PGID: '1000' 58 | 59 | # MAIN DEPLOYMENT ############################################################# 60 | - name: 'Deploying {{pgrole}}' 61 | docker_container: 62 | name: '{{pgrole}}' 63 | image: '{{image}}' 64 | pull: yes 65 | published_ports: 66 | - '{{ports.stdout}}{{extport}}:{{intport}}' 67 | volumes: '{{pg_volumes}}' 68 | env: '{{pg_env}}' 69 | restart_policy: unless-stopped 70 | networks: 71 | - name: plexguide 72 | aliases: 73 | - '{{pgrole}}' 74 | state: started 75 | labels: '{{pg_labels}}' 76 | -------------------------------------------------------------------------------- /apps/sonarr4k.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Author(s): Admin9705 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - hosts: localhost 10 | gather_facts: false 11 | tasks: 12 | # CORE (MANDATORY) DO NOT CHANGE ########################################### 13 | 14 | - name: 'Set Known Facts' 15 | set_fact: 16 | pgrole: 'sonarr4k' 17 | intport: '8989' 18 | extport: '8984' 19 | image: 'linuxserver/sonarr:preview' 20 | 21 | # CORE (MANDATORY) ############################################################ 22 | - name: 'Including cron job' 23 | include_tasks: '/opt/coreapps/apps/_core.yml' 24 | 25 | - name: 'Including plugins' 26 | include_tasks: '/opt/coreapps/apps/_plugins.yml' 27 | 28 | # LABELS ###################################################################### 29 | - name: 'Adding Traefik' 30 | set_fact: 31 | pg_labels: 32 | traefik.enable: 'true' 33 | traefik.port: '{{intport}}' 34 | traefik.frontend.auth.forward.address: '{{gauth}}' 35 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 36 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 37 | traefik.frontend.headers.SSLRedirect: 'true' 38 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 39 | traefik.frontend.headers.STSPreload: 'true' 40 | traefik.frontend.headers.STSSeconds: '315360000' 41 | traefik.frontend.headers.browserXSSFilter: 'true' 42 | traefik.frontend.headers.contentTypeNosniff: 'true' 43 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 44 | traefik.frontend.headers.forceSTSHeader: 'true' 45 | 46 | - name: 'Setting {{pgrole}} Volumes' 47 | set_fact: 48 | pg_volumes: 49 | - '{{path.stdout}}:{{path.stdout}}' 50 | - '/opt/appdata/{{pgrole}}:/config' 51 | - '/opt/appdata/{{pgrole}}/mp4_automator:/config_mp4_automator' 52 | 53 | - name: 'Setting {{pgrole}} ENV' 54 | set_fact: 55 | pg_env: 56 | PUID: '1000' 57 | PGID: '1000' 58 | 59 | # MAIN DEPLOYMENT ############################################################# 60 | - name: 'Deploying {{pgrole}}' 61 | docker_container: 62 | name: '{{pgrole}}' 63 | image: '{{image}}' 64 | pull: yes 65 | published_ports: 66 | - '{{ports.stdout}}{{extport}}:{{intport}}' 67 | volumes: '{{pg_volumes}}' 68 | env: '{{pg_env}}' 69 | restart_policy: unless-stopped 70 | networks: 71 | - name: plexguide 72 | aliases: 73 | - '{{pgrole}}' 74 | state: started 75 | labels: '{{pg_labels}}' 76 | -------------------------------------------------------------------------------- /apps/sonarrhdr.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Author(s): Admin9705 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - hosts: localhost 10 | gather_facts: false 11 | tasks: 12 | # CORE (MANDATORY) DO NOT CHANGE ########################################### 13 | 14 | - name: 'Set Known Facts' 15 | set_fact: 16 | pgrole: 'sonarrhdr' 17 | intport: '8989' 18 | extport: '8987' 19 | image: 'linuxserver/sonarr:preview' 20 | 21 | # CORE (MANDATORY) ############################################################ 22 | - name: 'Including cron job' 23 | include_tasks: '/opt/coreapps/apps/_core.yml' 24 | 25 | - name: 'Including plugins' 26 | include_tasks: '/opt/coreapps/apps/_plugins.yml' 27 | # LABELS ###################################################################### 28 | - name: 'Adding Traefik' 29 | set_fact: 30 | pg_labels: 31 | traefik.enable: 'true' 32 | traefik.port: '{{intport}}' 33 | traefik.frontend.auth.forward.address: '{{gauth}}' 34 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 35 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 36 | traefik.frontend.headers.SSLRedirect: 'true' 37 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 38 | traefik.frontend.headers.STSPreload: 'true' 39 | traefik.frontend.headers.STSSeconds: '315360000' 40 | traefik.frontend.headers.browserXSSFilter: 'true' 41 | traefik.frontend.headers.contentTypeNosniff: 'true' 42 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 43 | traefik.frontend.headers.forceSTSHeader: 'true' 44 | 45 | - name: 'Setting {{pgrole}} Volumes' 46 | set_fact: 47 | pg_volumes: 48 | - '{{path.stdout}}:{{path.stdout}}' 49 | - '/opt/appdata/{{pgrole}}:/config' 50 | - '/opt/appdata/{{pgrole}}/mp4_automator:/config_mp4_automator' 51 | 52 | - name: 'Setting {{pgrole}} ENV' 53 | set_fact: 54 | pg_env: 55 | PUID: '1000' 56 | PGID: '1000' 57 | 58 | # MAIN DEPLOYMENT ############################################################# 59 | - name: 'Deploying {{pgrole}}' 60 | docker_container: 61 | name: '{{pgrole}}' 62 | image: '{{image}}' 63 | pull: yes 64 | published_ports: 65 | - '{{ports.stdout}}{{extport}}:{{intport}}' 66 | volumes: '{{pg_volumes}}' 67 | env: '{{pg_env}}' 68 | restart_policy: unless-stopped 69 | networks: 70 | - name: plexguide 71 | aliases: 72 | - '{{pgrole}}' 73 | state: started 74 | labels: '{{pg_labels}}' 75 | -------------------------------------------------------------------------------- /apps/tautulli.yml: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Author(s): Admin9705 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | ################################################################################ 8 | --- 9 | - hosts: localhost 10 | gather_facts: false 11 | tasks: 12 | # FACTS ####################################################################### 13 | - name: 'Set Known Facts' 14 | set_fact: 15 | pgrole: 'tautulli' 16 | intport: '8181' 17 | extport: '8181' 18 | image: 'linuxserver/tautulli' 19 | 20 | # CORE (MANDATORY) ############################################################ 21 | - name: 'Including cron job' 22 | include_tasks: '/opt/coreapps/apps/_core.yml' 23 | - name: 'Including plugins ' 24 | include_tasks: '/opt/coreapps/apps/_plugins.yml' 25 | - name: 'Checking for existing app data' 26 | stat: 27 | path: /opt/appdata/{{pgrole}}/config.ini 28 | register: confcheck 29 | 30 | # LABELS ###################################################################### 31 | - name: 'Adding Traefik' 32 | set_fact: 33 | pg_labels: 34 | traefik.enable: 'true' 35 | traefik.port: '{{intport}}' 36 | #traefik.frontend.auth.forward.address: '{{gauth}}' 37 | traefik.frontend.rule: 'Host:{{pgrole}}.{{domain.stdout}}{{tldset}}{{cname}}' 38 | traefik.frontend.headers.SSLHost: '{{domain.stdout}}' 39 | traefik.frontend.headers.SSLRedirect: 'true' 40 | traefik.frontend.headers.STSIncludeSubdomains: 'true' 41 | traefik.frontend.headers.STSPreload: 'true' 42 | traefik.frontend.headers.STSSeconds: '315360000' 43 | traefik.frontend.headers.browserXSSFilter: 'true' 44 | traefik.frontend.headers.contentTypeNosniff: 'true' 45 | traefik.frontend.headers.customResponseHeaders: 'X-Robots-Tag:noindex,nofollow,nosnippet,noarchive,notranslate,noimageindex' 46 | traefik.frontend.headers.forceSTSHeader: 'true' 47 | 48 | - name: 'Setting {{pgrole}} Volumes' 49 | set_fact: 50 | pg_volumes: 51 | - '/opt/appdata/{{pgrole}}:/config' 52 | - '/opt/appdata/plex/database/Library/Application Support/Plex Media Server/Logs:/logs' 53 | - '/opt/appdata/{{pgrole}}/scripts:/scripts' 54 | - '/etc/localtime:/etc/localtime' 55 | 56 | - name: 'Setting {{pgrole}} ENV' 57 | set_fact: 58 | pg_env: 59 | PUID: '1000' 60 | PGID: '1000' 61 | # MAIN DEPLOYMENT ############################################################# 62 | - name: 'Deploying {{pgrole}}' 63 | docker_container: 64 | name: '{{pgrole}}' 65 | image: '{{image}}' 66 | pull: yes 67 | published_ports: 68 | - '{{ports.stdout}}{{extport}}:{{intport}}' 69 | volumes: '{{pg_volumes}}' 70 | env: '{{pg_env}}' 71 | restart_policy: unless-stopped 72 | networks: 73 | - name: plexguide 74 | aliases: 75 | - '{{pgrole}}' 76 | state: started 77 | labels: '{{pg_labels}}' 78 | 79 | # Undeployed ######################################################################## 80 | - name: 'Configuring {{pgrole}} for first time use' 81 | block: 82 | - name: 'Waiting for {{pgrole}} to start' 83 | wait_for: 84 | path: '/opt/appdata/{{pgrole}}/config.ini' 85 | state: present 86 | - name: 'Stop Container' 87 | docker_container: 88 | name: '{{pgrole}}' 89 | state: stopped 90 | - name: 'Restart {{pgrole}}' 91 | docker_container: 92 | name: '{{pgrole}}' 93 | state: started 94 | when: not confcheck.stat.exists 95 | 96 | - name: 'Update {{pgrole}} for first time use' 97 | block: 98 | - pause: 99 | prompt: "Wait for {{pgrole}} start up" 100 | seconds: 5 101 | 102 | - name: 'update {{pgrole}}' 103 | shell: 'docker exec {{pgrole}} apk update && docker exec {{pgrole}} apk upgrade' 104 | 105 | - name: 'pip update for {{pgrole}}' 106 | shell: 'docker exec {{pgrole}} pip install --upgrade PIP' 107 | 108 | - name: 'pip install jsonrpclib-pelix for {{pgrole}}' 109 | shell: 'docker exec {{pgrole}} pip install jsonrpclib-pelix' 110 | 111 | when: confcheck.stat.exists 112 | -------------------------------------------------------------------------------- /apps/templates/nzbget/mp4_automator/autoProcess.ini: -------------------------------------------------------------------------------- 1 | [Radarr] 2 | host = localhost 3 | port = 7878 4 | web_root = 5 | ssl = False 6 | apikey = 7 | 8 | [MP4] 9 | ffmpeg = /usr/bin/ffmpeg 10 | ffprobe = /usr/bin/ffprobe 11 | threads = auto 12 | output_directory = 13 | copy_to = 14 | move_to = 15 | output_extension = mp4 16 | output_format = mp4 17 | delete_original = True 18 | relocate_moov = True 19 | video-codec = h264,x264 20 | video-bitrate = 21 | video-crf = 22 | video-max-width = 23 | video-profile = 24 | h264-max-level = 25 | use-qsv-decoder-with-encoder = True 26 | use-hevc-qsv-decoder = False 27 | enable_dxva2_gpu_decode = False 28 | ios-audio = True 29 | ios-first-track-only = False 30 | ios-audio-filter = 31 | ios-move-last = False 32 | max-audio-channels = 33 | audio-codec = ac3 34 | audio-language = 35 | audio-default-language = 36 | audio-channel-bitrate = 37 | audio-filter = 38 | audio-copy-original = False 39 | subtitle-codec = mov_text 40 | subtitle-language = 41 | subtitle-default-language = 42 | subtitle-encoding = 43 | fullpathguess = True 44 | convert-mp4 = False 45 | tagfile = True 46 | tag-language = en 47 | download-artwork = Poster 48 | download-subs = False 49 | embed-subs = True 50 | embed-only-internal-subs = False 51 | sub-providers = addic7ed,podnapisi,thesubdb,opensubtitles 52 | permissions = 0777 53 | post-process = False 54 | pix-fmt = 55 | aac_adtstoasc = False 56 | -------------------------------------------------------------------------------- /apps/templates/nzbget/scripts.yml: -------------------------------------------------------------------------------- 1 | - name: creating tmp dir for clones 2 | shell: mkdir -p /tmp/nzbget 3 | 4 | - name: Cloning revers_name.py 5 | unarchive: 6 | src: https://github.com/Prinz23/nzbget-pp-reverse/archive/master.zip 7 | dest: /tmp/nzbget 8 | keep_newer: no 9 | owner: '1000' 10 | group: '1000' 11 | mode: 0775 12 | copy: no 13 | 14 | - name: Cloning Passwort Detector.py 15 | unarchive: 16 | src: https://github.com/JVMed/PasswordDetector/archive/master.zip 17 | dest: /tmp/nzbget 18 | keep_newer: no 19 | owner: '1000' 20 | group: '1000' 21 | mode: 0775 22 | copy: no 23 | 24 | - name: Cloning Fake Detctor.py 25 | unarchive: 26 | src: https://github.com/Prinz23/FakeDetector/archive/master.zip 27 | dest: /tmp/nzbget 28 | keep_newer: no 29 | owner: '1000' 30 | group: '1000' 31 | mode: 0775 32 | copy: no 33 | 34 | - name: Cloning lot of scripts 35 | unarchive: 36 | src: https://github.com/clinton-hall/GetScripts/archive/master.zip 37 | dest: /tmp/nzbget 38 | keep_newer: no 39 | owner: '1000' 40 | group: '1000' 41 | mode: 0775 42 | copy: no 43 | 44 | - name: passwort detector installing 45 | copy: 46 | src: '/tmp/nzbget/PasswordDetector-master/' 47 | dest: '/opt/appdata/nzbget/scripts' 48 | force: yes 49 | 50 | - name: revers_master 51 | copy: 52 | src: '/tmp/nzbget/nzbget-pp-reverse-master/' 53 | dest: '/opt/appdata/nzbget/scripts' 54 | force: yes 55 | 56 | - name: lot of useful scriptss 57 | copy: 58 | src: '/tmp/nzbget/GetScripts-master/' 59 | dest: '/opt/appdata/nzbget/scripts' 60 | force: yes 61 | 62 | - name: FakeDetector installing 63 | copy: 64 | src: '/tmp/nzbget/FakeDetector-master/' 65 | dest: '/opt/appdata/nzbget/scripts' 66 | force: yes 67 | 68 | - name: remove temp folder 69 | shell: rm -rf /tmp/nzbget 70 | 71 | # scripts permissions 72 | - name: 'Setting permissions on scripts' 73 | shell: 'chmod -R 775 /opt/appdata/nzbget/scripts' 74 | -------------------------------------------------------------------------------- /apps/templates/nzbget/scripts/DeleteSamples.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Maintainer: Admin9705 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | # 8 | # Additions: clinton-hall - https://github.com/Prinz23 9 | ################################################################################ 10 | import os 11 | import sys 12 | 13 | # NZBGet Exit Codes 14 | NZBGET_POSTPROCESS_PARCHECK = 92 15 | NZBGET_POSTPROCESS_SUCCESS = 93 16 | NZBGET_POSTPROCESS_ERROR = 94 17 | NZBGET_POSTPROCESS_NONE = 95 18 | 19 | def is_sample(filePath, inputName, maxSampleSize, SampleIDs): 20 | # 200 MB in bytes 21 | SIZE_CUTOFF = int(maxSampleSize) * 1024 * 1024 22 | if os.path.getsize(filePath) < SIZE_CUTOFF: 23 | if 'SizeOnly' in SampleIDs: 24 | return True 25 | # Ignore 'sample' in files unless 'sample' in Torrent Name 26 | for ident in SampleIDs: 27 | if ident.lower() in filePath.lower() and not ident.lower() in inputName.lower(): 28 | return True 29 | # Return False if none of these were met. 30 | return False 31 | 32 | if not os.environ.has_key('NZBOP_SCRIPTDIR'): 33 | print "This script can only be called from NZBGet (11.0 or later)." 34 | sys.exit(0) 35 | 36 | if os.environ['NZBOP_VERSION'][0:5] < '11.0': 37 | print "NZBGet Version %s is not supported. Please update NZBGet." % (str(os.environ['NZBOP_VERSION'])) 38 | sys.exit(0) 39 | 40 | print "Script triggered from NZBGet Version %s." % (str(os.environ['NZBOP_VERSION'])) 41 | status = 0 42 | if os.environ.has_key('NZBPP_TOTALSTATUS'): 43 | if not os.environ['NZBPP_TOTALSTATUS'] == 'SUCCESS': 44 | print "Download failed with status %s." % (os.environ['NZBPP_STATUS']) 45 | status = 1 46 | 47 | else: 48 | # Check par status 49 | if os.environ['NZBPP_PARSTATUS'] == '1' or os.environ['NZBPP_PARSTATUS'] == '4': 50 | print "Par-repair failed, setting status \"failed\"." 51 | status = 1 52 | 53 | # Check unpack status 54 | if os.environ['NZBPP_UNPACKSTATUS'] == '1': 55 | print "Unpack failed, setting status \"failed\"." 56 | status = 1 57 | 58 | if os.environ['NZBPP_UNPACKSTATUS'] == '0' and os.environ['NZBPP_PARSTATUS'] == '0': 59 | # Unpack was skipped due to nzb-file properties or due to errors during par-check 60 | 61 | if os.environ['NZBPP_HEALTH'] < 1000: 62 | print "Download health is compromised and Par-check/repair disabled or no .par2 files found. Setting status \"failed\"." 63 | print "Please check your Par-check/repair settings for future downloads." 64 | status = 1 65 | 66 | else: 67 | print "Par-check/repair disabled or no .par2 files found, and Unpack not required. Health is ok so handle as though download successful." 68 | print "Please check your Par-check/repair settings for future downloads." 69 | 70 | # Check if destination directory exists (important for reprocessing of history items) 71 | if not os.path.isdir(os.environ['NZBPP_DIRECTORY']): 72 | print "Nothing to post-process: destination directory", os.environ['NZBPP_DIRECTORY'], "doesn't exist. Setting status \"failed\"." 73 | status = 1 74 | 75 | # All checks done, now launching the script. 76 | if status == 1: 77 | sys.exit(NZBGET_POSTPROCESS_NONE) 78 | 79 | mediaContainer = os.environ['NZBPO_MEDIAEXTENSIONS'].split(',') 80 | SampleIDs = os.environ['NZBPO_SAMPLEIDS'].split(',') 81 | for dirpath, dirnames, filenames in os.walk(os.environ['NZBPP_DIRECTORY']): 82 | for file in filenames: 83 | filePath = os.path.join(dirpath, file) 84 | fileName, fileExtension = os.path.splitext(file) 85 | if fileExtension in mediaContainer or ".*" in mediaContainer : # If the file is a video file 86 | if is_sample(filePath, os.environ['NZBPP_NZBNAME'], os.environ['NZBPO_MAXSAMPLESIZE'], SampleIDs): # Ignore samples 87 | print "Deleting sample file: ", filePath 88 | try: 89 | os.unlink(filePath) 90 | except: 91 | print "Error: unable to delete file", filePath 92 | sys.exit(NZBGET_POSTPROCESS_ERROR) 93 | sys.exit(NZBGET_POSTPROCESS_SUCCESS) 94 | -------------------------------------------------------------------------------- /apps/templates/nzbget/scripts/flatten.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | # 3 | ############################################################################## 4 | ### NZBGET POST-PROCESSING SCRIPT ### 5 | 6 | # Flatten all downloaded files into the root download directory. 7 | # 8 | # This removes all of the sub-folders created by the unpack process. 9 | # This should run before other scripts. 10 | # 11 | # NOTE: This script requires Python to be installed on your system. 12 | ############################################################################## 13 | ### OPTIONS ### 14 | 15 | # Destination Directory. 16 | # 17 | # Set the directory where you want all files to be moved to. 18 | # Use this if you want all downloaded files in a single "root" directory. 19 | # If left blank, files will all be "flattened" into the individual download's sub-directory. 20 | #DestinationDirectory= 21 | 22 | # Append Categories (yes, no). 23 | # 24 | # If using the Destination Directory above, then this option will append the download category. 25 | #AppendCategories=no 26 | 27 | 28 | ### NZBGET POST-PROCESSING SCRIPT ### 29 | ############################################################################## 30 | import os 31 | import sys 32 | import shutil 33 | 34 | # NZBGet Exit Codes 35 | NZBGET_POSTPROCESS_PARCHECK = 92 36 | NZBGET_POSTPROCESS_SUCCESS = 93 37 | NZBGET_POSTPROCESS_ERROR = 94 38 | NZBGET_POSTPROCESS_NONE = 95 39 | 40 | if 'NZBOP_SCRIPTDIR' not in os.environ: 41 | print("This script can only be called from NZBGet (11.0 or later).") 42 | sys.exit(0) 43 | 44 | if os.environ['NZBOP_VERSION'][0:5] < '11.0': 45 | print("[ERROR] NZBGet Version %s is not supported. Please update NZBGet." % (str(os.environ['NZBOP_VERSION']))) 46 | sys.exit(0) 47 | 48 | print("Script triggered from NZBGet Version %s." % (str(os.environ['NZBOP_VERSION']))) 49 | status = 0 50 | if 'NZBPP_TOTALSTATUS' in os.environ: 51 | if not os.environ['NZBPP_TOTALSTATUS'] == 'SUCCESS': 52 | print("[ERROR] Download failed with status %s." % (os.environ['NZBPP_STATUS'])) 53 | status = 1 54 | 55 | else: 56 | # Check par status 57 | if os.environ['NZBPP_PARSTATUS'] == '1' or os.environ['NZBPP_PARSTATUS'] == '4': 58 | print("[ERROR] Par-repair failed, setting status \"failed\".") 59 | status = 1 60 | 61 | # Check unpack status 62 | if os.environ['NZBPP_UNPACKSTATUS'] == '1': 63 | print("[ERROR] Unpack failed, setting status \"failed\".") 64 | status = 1 65 | 66 | if os.environ['NZBPP_UNPACKSTATUS'] == '0' and os.environ['NZBPP_PARSTATUS'] == '0': 67 | # Unpack was skipped due to nzb-file properties or due to errors during par-check 68 | 69 | if os.environ['NZBPP_HEALTH'] < 1000: 70 | print("[ERROR] Download health is compromised and Par-check/repair disabled or no .par2 files found. Setting status \"failed\".") 71 | print("[ERROR] Please check your Par-check/repair settings for future downloads.") 72 | status = 1 73 | 74 | else: 75 | print("[ERROR] Par-check/repair disabled or no .par2 files found, and Unpack not required. Health is ok so handle as though download successful.") 76 | print("[WARNING] Please check your Par-check/repair settings for future downloads.") 77 | 78 | # Check if destination directory exists (important for reprocessing of history items) 79 | if not os.path.isdir(os.environ['NZBPP_DIRECTORY']): 80 | print("[ERROR] Nothing to post-process: destination directory", os.environ['NZBPP_DIRECTORY'], "doesn't exist. Setting status \"failed\".") 81 | status = 1 82 | 83 | # All checks done, now launching the script. 84 | if status == 1: 85 | sys.exit(NZBGET_POSTPROCESS_NONE) 86 | 87 | def removeEmptyFolders(path, removeRoot=True): 88 | #Function to remove empty folders 89 | if not os.path.isdir(path): 90 | return 91 | 92 | # remove empty subfolders 93 | print("[INFO] Checking for empty folders in:%s" % path) 94 | files = os.listdir(path) 95 | if len(files): 96 | for f in files: 97 | fullpath = os.path.join(path, f) 98 | if os.path.isdir(fullpath): 99 | removeEmptyFolders(fullpath) 100 | 101 | # if folder empty, delete it 102 | files = os.listdir(path) 103 | if len(files) == 0 and removeRoot: 104 | print("[INFO] Removing empty folder:%s" % path) 105 | os.rmdir(path) 106 | 107 | directory = os.path.normpath(os.environ['NZBPP_DIRECTORY']) 108 | if os.environ['NZBPO_DESTINATIONDIRECTORY'] and os.path.isdir(os.environ['NZBPO_DESTINATIONDIRECTORY']): 109 | destination = os.environ['NZBPO_DESTINATIONDIRECTORY'] 110 | if os.environ['NZBPO_APPENDCATEGORIES'] == 'yes': 111 | destination = os.path.join(destination, os.environ['NZBPP_CATEGORY']) 112 | else: 113 | destination = directory 114 | print("Flattening directory: %s" % (directory)) 115 | for dirpath, dirnames, filenames in os.walk(directory): 116 | for fileName in filenames: 117 | outputFile = os.path.join(dirpath, fileName) 118 | if dirpath == directory: 119 | continue 120 | target = os.path.join(destination, fileName) 121 | try: 122 | shutil.move(outputFile, target) 123 | except: 124 | print("[ERROR] Could not flatten %s" % outputFile) 125 | removeEmptyFolders(directory) # Cleanup empty directories 126 | sys.exit(NZBGET_POSTPROCESS_SUCCESS) 127 | -------------------------------------------------------------------------------- /apps/templates/nzbget/scripts/hash.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | # 3 | # Title: PGBlitz (Reference Title File) 4 | # Maintainer: Admin9705 5 | # URL: https://pgblitz.com - http://github.pgblitz.com 6 | # GNU: General Public License v3.0 7 | # 8 | # Original Author: clinton-hall 9 | # https://github.com/clinton-hall/GetScripts/blob/master/SafeRename.py 10 | # 11 | # Modified By: desimaniac (No Acknowledgement of Source Above) 12 | ################################################################################ 13 | import os 14 | import re 15 | import shutil 16 | import sys 17 | 18 | # NZBGet Exit Codes 19 | NZBGET_POSTPROCESS_PARCHECK = 92 20 | NZBGET_POSTPROCESS_SUCCESS = 93 21 | NZBGET_POSTPROCESS_ERROR = 94 22 | NZBGET_POSTPROCESS_NONE = 95 23 | 24 | ############################################################ 25 | # EXTENSION STUFF 26 | ############################################################ 27 | 28 | def do_check(): 29 | if not os.environ.has_key('NZBOP_SCRIPTDIR'): 30 | print "This script can only be called from NZBGet (11.0 or later)." 31 | sys.exit(0) 32 | 33 | if os.environ['NZBOP_VERSION'][0:5] < '11.0': 34 | print "[ERROR] NZBGet Version %s is not supported. Please update NZBGet." % (str(os.environ['NZBOP_VERSION'])) 35 | sys.exit(0) 36 | 37 | print "Script triggered from NZBGet Version %s." % (str(os.environ['NZBOP_VERSION'])) 38 | 39 | status = 0 40 | if 'NZBPP_TOTALSTATUS' in os.environ: 41 | if not os.environ['NZBPP_TOTALSTATUS'] == 'SUCCESS': 42 | print "[ERROR] Download failed with status %s." % (os.environ['NZBPP_STATUS']) 43 | status = 1 44 | else: 45 | # Check par status 46 | if os.environ['NZBPP_PARSTATUS'] == '1' or os.environ['NZBPP_PARSTATUS'] == '4': 47 | print "[ERROR] Par-repair failed, setting status \"failed\"." 48 | status = 1 49 | 50 | # Check unpack status 51 | if os.environ['NZBPP_UNPACKSTATUS'] == '1': 52 | print "[ERROR] Unpack failed, setting status \"failed\"." 53 | status = 1 54 | 55 | if os.environ['NZBPP_UNPACKSTATUS'] == '0' and os.environ['NZBPP_PARSTATUS'] == '0': 56 | # Unpack was skipped due to nzb-file properties or due to errors during par-check 57 | 58 | if os.environ['NZBPP_HEALTH'] < 1000: 59 | print "[ERROR] Download health is compromised and Par-check/repair disabled or no .par2 files found. " \ 60 | "Setting status \"failed\"." 61 | print "[ERROR] Please check your Par-check/repair settings for future downloads." 62 | status = 1 63 | 64 | else: 65 | print "[ERROR] Par-check/repair disabled or no .par2 files found, and Unpack not required. Health is " \ 66 | "ok so handle as though download successful." 67 | print "[WARNING] Please check your Par-check/repair settings for future downloads." 68 | 69 | # Check if destination directory exists (important for reprocessing of history items) 70 | if not os.path.isdir(os.environ['NZBPP_DIRECTORY']): 71 | print "[ERROR] Nothing to post-process: destination directory", os.environ[ 72 | 'NZBPP_DIRECTORY'], "doesn't exist. Setting status \"failed\"." 73 | status = 1 74 | 75 | # All checks done, now launching the script. 76 | if status == 1: 77 | sys.exit(NZBGET_POSTPROCESS_NONE) 78 | 79 | 80 | def get_file_name(path): 81 | try: 82 | file_name = os.path.basename(path) 83 | extensions = re.findall(r'\.([^.]+)', file_name) 84 | ext = '.'.join(extensions) 85 | name = file_name.replace(".%s" % ext, '') 86 | return name, ext 87 | except Exception: 88 | pass 89 | return None 90 | 91 | 92 | def is_file_hash(file_name): 93 | hash_regexp = [ 94 | r'^[a-fA-F0-9]{40}$', 95 | r'^[a-fA-F0-9]{32}$', 96 | r'^[a-f0-9]{128}$', 97 | r'^[a-zA-Z0-9]{42}$' 98 | ] 99 | for hash in hash_regexp: 100 | if re.match(hash, file_name): 101 | return True 102 | return False 103 | 104 | 105 | def find_files(folder, extension=None, depth=None): 106 | file_list = [] 107 | start_count = folder.count(os.sep) 108 | for path, subdirs, files in os.walk(folder, topdown=True): 109 | for name in files: 110 | if depth and path.count(os.sep) - start_count >= depth: 111 | del subdirs[:] 112 | continue 113 | file = os.path.join(path, name) 114 | if not extension: 115 | file_list.append(file) 116 | else: 117 | if file.lower().endswith(extension.lower()): 118 | file_list.append(file) 119 | 120 | return sorted(file_list, key=lambda x: x.count(os.path.sep), reverse=True) 121 | 122 | 123 | ############################################################ 124 | # MAIN 125 | ############################################################ 126 | 127 | # do checks 128 | do_check() 129 | 130 | # retrieve required variables 131 | directory = os.path.normpath(os.environ['NZBPP_DIRECTORY']) 132 | nzb_name = os.environ['NZBPP_NZBFILENAME'] 133 | if nzb_name is None: 134 | print("[ERROR] Unable to retrieve NZBPP_NZBFILENAME") 135 | sys.exit(NZBGET_POSTPROCESS_ERROR) 136 | nzb_name = nzb_name.replace('.nzb', '') 137 | 138 | print("[INFO] Using \"%s\" for hashed filenames" % nzb_name) 139 | print("[INFO] Scanning \"%s\" for hashed filenames" % directory) 140 | 141 | # scan for files 142 | found_files = find_files(directory) 143 | if not found_files: 144 | print("[INFO] No files were found in \"%s\"" % directory) 145 | sys.exit(NZBGET_POSTPROCESS_NONE) 146 | else: 147 | print("[INFO] Found %d files to check for hashed filenames" % len(found_files)) 148 | # loop files checking for file hash 149 | moved_files = 0 150 | for found_file_path in found_files: 151 | # set variable 152 | dir_name = os.path.dirname(found_file_path) 153 | file_name, file_ext = get_file_name(found_file_path) 154 | 155 | # is this a file hash 156 | if is_file_hash(file_name): 157 | new_file_path = os.path.join(dir_name, "%s.%s" % (nzb_name, file_ext)) 158 | print("[INFO] Moving \"%s\" to \"%s\"" % (found_file_path, new_file_path)) 159 | try: 160 | shutil.move(found_file_path, new_file_path) 161 | moved_files += 1 162 | except Exception: 163 | print("[ERROR] Failed moving \"%s\" to \"%s\"" % (found_file_path, new_file_path)) 164 | 165 | print("[INFO] Finished processing \"%s\", moved %d files" % (directory, moved_files)) 166 | 167 | sys.exit(NZBGET_POSTPROCESS_SUCCESS) 168 | -------------------------------------------------------------------------------- /apps/templates/nzbget/scripts/rarfile/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/PGBlitz/Apps-Core/3307170478e03fbac23d0d5b4aed3461b57879b1/apps/templates/nzbget/scripts/rarfile/__init__.py -------------------------------------------------------------------------------- /apps/templates/nzbget/scripts/unzip.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | # 3 | ############################################################################## 4 | ### NZBGET SCAN SCRIPT ### 5 | 6 | # Unzips zipped nzbs. 7 | # 8 | # NOTE: This script requires Python to be installed on your system. 9 | 10 | ############################################################################## 11 | ### OPTIONS ### 12 | ### NZBGET SCAN SCRIPT ### 13 | ############################################################################## 14 | 15 | import os, zipfile, tarfile, gzip, pickle, datetime, re, struct, locale 16 | import rarfile.rarfile as rarfile 17 | 18 | from gzip import FEXTRA, FNAME 19 | 20 | if 'nt' == os.name: 21 | import ctypes 22 | 23 | class WinEnv: 24 | def __init__(self): 25 | pass 26 | 27 | @staticmethod 28 | def get_environment_variable(name): 29 | name = unicode(name) # ensures string argument is unicode 30 | n = ctypes.windll.kernel32.GetEnvironmentVariableW(name, None, 0) 31 | result = None 32 | if n: 33 | buf = ctypes.create_unicode_buffer(u'\0'*n) 34 | ctypes.windll.kernel32.GetEnvironmentVariableW(name, buf, n) 35 | result = buf.value 36 | return result 37 | 38 | def __getitem__(self, key): 39 | return self.get_environment_variable(key) 40 | 41 | def get(self, key, default=None): 42 | r = self.get_environment_variable(key) 43 | return r if r is not None else default 44 | 45 | env_var = WinEnv() 46 | else: 47 | class LinuxEnv(object): 48 | def __init__(self, environ): 49 | self.environ = environ 50 | 51 | def __getitem__(self, key): 52 | v = self.environ.get(key) 53 | try: 54 | return v.decode(SYS_ENCODING) if isinstance(v, str) else v 55 | except (UnicodeDecodeError, UnicodeEncodeError): 56 | return v 57 | 58 | def get(self, key, default=None): 59 | v = self[key] 60 | return v if v is not None else default 61 | 62 | env_var = LinuxEnv(os.environ) 63 | 64 | 65 | SYS_ENCODING = None 66 | try: 67 | locale.setlocale(locale.LC_ALL, '') 68 | except (locale.Error, IOError): 69 | pass 70 | try: 71 | SYS_ENCODING = locale.getpreferredencoding() 72 | except (locale.Error, IOError): 73 | pass 74 | if not SYS_ENCODING or SYS_ENCODING in ('ANSI_X3.4-1968', 'US-ASCII', 'ASCII'): 75 | SYS_ENCODING = 'UTF-8' 76 | 77 | 78 | filename = env_var.get('NZBNP_FILENAME') 79 | if re.search(r"\.tar\.gz$", filename, flags=re.I) is None: 80 | ext = os.path.splitext(filename)[1].lower() 81 | else: 82 | ext = '.tar.gz' 83 | cat = env_var.get('NZBNP_CATEGORY') 84 | dir = env_var.get('NZBNP_DIRECTORY') 85 | prio = env_var.get('NZBNP_PRIORITY') 86 | top = env_var.get('NZBNP_TOP') 87 | pause = env_var.get('NZBNP_PAUSED') 88 | if 'NZBNP_DUPEKEY' in os.environ: 89 | dupekey = env_var.get('NZBNP_DUPEKEY') 90 | dupescore = env_var.get('NZBNP_DUPESCORE') 91 | dupemode = env_var.get('NZBNP_DUPEMODE') 92 | else: 93 | dupekey = None 94 | dupescore = None 95 | dupemode = None 96 | 97 | tmp_zipinfo = os.path.join(os.environ.get('NZBOP_TEMPDIR'), r'nzbget\unzip_scan\info') 98 | nzb_list = [] 99 | 100 | def read_gzip_info(gzipfile): 101 | gf = gzipfile.fileobj 102 | pos = gf.tell() 103 | 104 | # Read archive size 105 | gf.seek(-4, 2) 106 | size = struct.unpack(' **Note:** It is important that the plugin directory is named 'mobile' so that the supporting files are loaded correctly. 12 | > **Warning:** This plugin is not compatible with the ipad plugin. 13 | 14 | Optional plugins that add additional functionality: 15 | * _getdir: Allows you to browse directories from your server when adding a torrent. 16 | * erasedata: Allows you to delete with data when deleting a torrent. 17 | * seedingtime: Adds the fields Added and Finished to the torrent details page. 18 | * ratio: Allows you to see and set the ratio group for a torrent. 19 | * throttle: Allows you to see and set the channel for a torrent. 20 | 21 | ### Configuration 22 | There are three configurable boolean options and one multi-value option that you may set at the top of init.js. 23 | #### plugin.enableAutodetect 24 | true by default. This option sets whether mobile devices will be autodetected to enable the plugin. 25 | 26 | #### plugin.tabletsDetect 27 | true by default. This option sets whether to include tablets in the autodetection. 28 | 29 | #### plugin.eraseWithDataDefault 30 | false by default. This option sets the default state of the delete with data checkbox in the confirmation page when deleting a torrent. 31 | If in rutorrent you turned off 'Confirm when deleting torrents', this plugin will not display the confirmaion page either. In this case, the decision about deleting data will be determined by the value of this option. 32 | 33 | #### plugin.sort 34 | 'name' by default. Possible values: 'name', '-name', 'size', '-size', 'uploaded', '-uploaded', 'downloaded', '-downloaded', 'done', '-done', 'eta', '-eta', 'ul', '-ul', 'dl', '-dl', 'ratio', '-ratio', and if the seedingtime plugin is loaded 'addtime', '-addtime', 'seedingtime', '-seedingtime'. 35 | This option sets the default sort value of the torrent list. Without negative it's ascending, with negative it's descending. 36 | 37 | ### Utilization 38 | If you set plugin.enableAutodetect to true, the plugin will automaticaly load when detecting a mobile device. To force load the plugin in a desktop browser add '?mobile=1' to the end of the rutorrent url. 39 | 40 | ### Troubleshooting 41 | If you are experiencing problems with this plugin, for example it's not scrolling or there are overlapping elements, try these solutions. 42 | * Make sure the plugin directory is named 'mobile' or else it won't load the plugin specific css file called mobile.css 43 | * Make sure you don't have the ipad plugin installed. The ipad plugin will make it so you can't scroll in the mobile plugin. 44 | * If you are still having issues, submit an issue on github https://github.com/xombiemp/rutorrentMobile/issues and be sure to include as much detail as possible including: mobile device and OS and browser, server OS and webserver. 45 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/PGBlitz/Apps-Core/3307170478e03fbac23d0d5b4aed3461b57879b1/apps/templates/rutorrent/plugins/mobile/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/PGBlitz/Apps-Core/3307170478e03fbac23d0d5b4aed3461b57879b1/apps/templates/rutorrent/plugins/mobile/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/PGBlitz/Apps-Core/3307170478e03fbac23d0d5b4aed3461b57879b1/apps/templates/rutorrent/plugins/mobile/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/fonts/glyphicons-halflings-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/PGBlitz/Apps-Core/3307170478e03fbac23d0d5b4aed3461b57879b1/apps/templates/rutorrent/plugins/mobile/fonts/glyphicons-halflings-regular.woff2 -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/lang/cs.js: -------------------------------------------------------------------------------- 1 | /* 2 | * PLUGIN MOBILE 3 | * 4 | * Czech language file. 5 | * 6 | * Author: 7 | */ 8 | 9 | theUILang.SortTorrents = "Sort torrents by"; 10 | theUILang.acs = "Ascending"; 11 | theUILang.decs = "Descending"; 12 | 13 | thePlugins.get("mobile").langLoaded(); 14 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/lang/da.js: -------------------------------------------------------------------------------- 1 | /* 2 | * PLUGIN MOBILE 3 | * 4 | * Danish language file. 5 | * 6 | * Author: 7 | */ 8 | 9 | theUILang.SortTorrents = "Sort torrents by"; 10 | theUILang.acs = "Ascending"; 11 | theUILang.decs = "Descending"; 12 | 13 | thePlugins.get("mobile").langLoaded(); 14 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/lang/de.js: -------------------------------------------------------------------------------- 1 | /* 2 | * PLUGIN MOBILE 3 | * 4 | * German language file. 5 | * 6 | * Author: 7 | */ 8 | 9 | theUILang.SortTorrents = "Sortiere torrents nach"; 10 | theUILang.acs = "Aufsteigend"; 11 | theUILang.decs = "Absteigend"; 12 | 13 | thePlugins.get("mobile").langLoaded(); 14 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/lang/el.js: -------------------------------------------------------------------------------- 1 | /* 2 | * PLUGIN MOBILE 3 | * 4 | * Greek language file. 5 | * 6 | * Author: 7 | */ 8 | 9 | theUILang.SortTorrents = "Sort torrents by"; 10 | theUILang.acs = "Ascending"; 11 | theUILang.decs = "Descending"; 12 | 13 | thePlugins.get("mobile").langLoaded(); 14 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/lang/en.js: -------------------------------------------------------------------------------- 1 | /* 2 | * PLUGIN MOBILE 3 | * 4 | * English language file. 5 | * 6 | * Author: 7 | */ 8 | 9 | theUILang.SortTorrents = "Sort torrents by"; 10 | theUILang.acs = "Ascending"; 11 | theUILang.decs = "Descending"; 12 | 13 | thePlugins.get("mobile").langLoaded(); 14 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/lang/es.js: -------------------------------------------------------------------------------- 1 | /* 2 | * PLUGIN MOBILE 3 | * 4 | * Spanish language file. 5 | * 6 | * Author: 7 | */ 8 | 9 | theUILang.SortTorrents = "Sort torrents by"; 10 | theUILang.acs = "Ascending"; 11 | theUILang.decs = "Descending"; 12 | 13 | thePlugins.get("mobile").langLoaded(); 14 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/lang/fi.js: -------------------------------------------------------------------------------- 1 | /* 2 | * PLUGIN MOBILE 3 | * 4 | * Finnish language file. 5 | * 6 | * Author: 7 | */ 8 | 9 | theUILang.SortTorrents = "Sort torrents by"; 10 | theUILang.acs = "Ascending"; 11 | theUILang.decs = "Descending"; 12 | 13 | thePlugins.get("mobile").langLoaded(); 14 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/lang/fr.js: -------------------------------------------------------------------------------- 1 | /* 2 | * PLUGIN MOBILE 3 | * 4 | * French language file. 5 | * 6 | * Author: 7 | */ 8 | 9 | theUILang.SortTorrents = "Trier les torrents par"; 10 | theUILang.acs = "Croissant"; 11 | theUILang.decs = "Décroissant"; 12 | 13 | thePlugins.get("mobile").langLoaded(); 14 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/lang/hu.js: -------------------------------------------------------------------------------- 1 | /* 2 | * PLUGIN MOBILE 3 | * 4 | * Hungarian language file. 5 | * 6 | * Author: 7 | */ 8 | 9 | theUILang.SortTorrents = "Sort torrents by"; 10 | theUILang.acs = "Ascending"; 11 | theUILang.decs = "Descending"; 12 | 13 | thePlugins.get("mobile").langLoaded(); 14 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/lang/it.js: -------------------------------------------------------------------------------- 1 | /* 2 | * PLUGIN MOBILE 3 | * 4 | * Italian language file. 5 | * 6 | * Author: 7 | */ 8 | 9 | theUILang.SortTorrents = "Sort torrents by"; 10 | theUILang.acs = "Ascending"; 11 | theUILang.decs = "Descending"; 12 | 13 | thePlugins.get("mobile").langLoaded(); 14 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/lang/lv.js: -------------------------------------------------------------------------------- 1 | /* 2 | * PLUGIN MOBILE 3 | * 4 | * Latvian language file. 5 | * 6 | * Author: 7 | */ 8 | 9 | theUILang.SortTorrents = "Sort torrents by"; 10 | theUILang.acs = "Ascending"; 11 | theUILang.decs = "Descending"; 12 | 13 | thePlugins.get("mobile").langLoaded(); 14 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/lang/nl.js: -------------------------------------------------------------------------------- 1 | /* 2 | * PLUGIN MOBILE 3 | * 4 | * Dutch language file. 5 | * 6 | * Author: 7 | */ 8 | 9 | theUILang.SortTorrents = "Sort torrents by"; 10 | theUILang.acs = "Ascending"; 11 | theUILang.decs = "Descending"; 12 | 13 | thePlugins.get("mobile").langLoaded(); 14 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/lang/pl.js: -------------------------------------------------------------------------------- 1 | /* 2 | * PLUGIN MOBILE 3 | * 4 | * Polish language file. 5 | * 6 | * Author: 7 | */ 8 | 9 | theUILang.SortTorrents = "Sort torrents by"; 10 | theUILang.acs = "Ascending"; 11 | theUILang.decs = "Descending"; 12 | 13 | thePlugins.get("mobile").langLoaded(); 14 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/lang/pt.js: -------------------------------------------------------------------------------- 1 | /* 2 | * PLUGIN MOBILE 3 | * 4 | * Portuguese language file. 5 | * 6 | * Author: 7 | */ 8 | 9 | theUILang.SortTorrents = "Sort torrents by"; 10 | theUILang.acs = "Ascending"; 11 | theUILang.decs = "Descending"; 12 | 13 | thePlugins.get("mobile").langLoaded(); 14 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/lang/ru.js: -------------------------------------------------------------------------------- 1 | /* 2 | * PLUGIN MOBILE 3 | * 4 | * Russian language file. 5 | * 6 | * Author: 7 | */ 8 | 9 | theUILang.SortTorrents = "Sort torrents by"; 10 | theUILang.acs = "Ascending"; 11 | theUILang.decs = "Descending"; 12 | 13 | thePlugins.get("mobile").langLoaded(); 14 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/lang/sk.js: -------------------------------------------------------------------------------- 1 | /* 2 | * PLUGIN MOBILE 3 | * 4 | * Slovak language file. 5 | * 6 | * Author: 7 | */ 8 | 9 | theUILang.SortTorrents = "Sort torrents by"; 10 | theUILang.acs = "Ascending"; 11 | theUILang.decs = "Descending"; 12 | 13 | thePlugins.get("mobile").langLoaded(); 14 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/lang/sr.js: -------------------------------------------------------------------------------- 1 | /* 2 | * PLUGIN MOBILE 3 | * 4 | * Serbian language file. 5 | * 6 | * Author: 7 | */ 8 | 9 | theUILang.SortTorrents = "Sort torrents by"; 10 | theUILang.acs = "Ascending"; 11 | theUILang.decs = "Descending"; 12 | 13 | thePlugins.get("mobile").langLoaded(); 14 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/lang/sv.js: -------------------------------------------------------------------------------- 1 | /* 2 | * PLUGIN MOBILE 3 | * 4 | * Swedish language file. 5 | * 6 | * Author: 7 | */ 8 | 9 | theUILang.SortTorrents = "Sort torrents by"; 10 | theUILang.acs = "Ascending"; 11 | theUILang.decs = "Descending"; 12 | 13 | thePlugins.get("mobile").langLoaded(); 14 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/lang/tr.js: -------------------------------------------------------------------------------- 1 | /* 2 | * PLUGIN MOBILE 3 | * 4 | * Turkish language file. 5 | * 6 | * Author: 7 | */ 8 | 9 | theUILang.SortTorrents = "Sort torrents by"; 10 | theUILang.acs = "Ascending"; 11 | theUILang.decs = "Descending"; 12 | 13 | thePlugins.get("mobile").langLoaded(); 14 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/lang/uk.js: -------------------------------------------------------------------------------- 1 | /* 2 | * PLUGIN MOBILE 3 | * 4 | * Ukrainian language file. 5 | * 6 | * Author: 7 | */ 8 | 9 | theUILang.SortTorrents = "Sort torrents by"; 10 | theUILang.acs = "Ascending"; 11 | theUILang.decs = "Descending"; 12 | 13 | thePlugins.get("mobile").langLoaded(); 14 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/lang/vi.js: -------------------------------------------------------------------------------- 1 | /* 2 | * PLUGIN MOBILE 3 | * 4 | * Vietnamese language file. 5 | * 6 | * Author: 7 | */ 8 | 9 | theUILang.SortTorrents = "Sort torrents by"; 10 | theUILang.acs = "Ascending"; 11 | theUILang.decs = "Descending"; 12 | 13 | thePlugins.get("mobile").langLoaded(); 14 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/lang/zh-cn.js: -------------------------------------------------------------------------------- 1 | /* 2 | * PLUGIN MOBILE 3 | * 4 | * Chinese Simplified language file. 5 | * 6 | * Author: 7 | */ 8 | 9 | theUILang.SortTorrents = "Sort torrents by"; 10 | theUILang.acs = "Ascending"; 11 | theUILang.decs = "Descending"; 12 | 13 | thePlugins.get("mobile").langLoaded(); 14 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/lang/zh-tw.js: -------------------------------------------------------------------------------- 1 | /* 2 | * PLUGIN MOBILE 3 | * 4 | * Chinese Traditional language file. 5 | * 6 | * Author: 7 | */ 8 | 9 | theUILang.SortTorrents = "Sort torrents by"; 10 | theUILang.acs = "Ascending"; 11 | theUILang.decs = "Descending"; 12 | 13 | thePlugins.get("mobile").langLoaded(); 14 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/mobile.css: -------------------------------------------------------------------------------- 1 | /*** General ***/ 2 | html, body { 3 | overflow: visible; 4 | } 5 | a, button, tr, select, input, label { 6 | -webkit-tap-highlight-color: transparent; 7 | } 8 | div input { 9 | margin: 0px; 10 | } 11 | select { 12 | width:auto; 13 | } 14 | .hiddenPath { 15 | display: none; 16 | } 17 | .table { 18 | margin-bottom: 0; 19 | } 20 | .tableFixHead { 21 | overflow-y: auto; 22 | margin-bottom: 0; 23 | } 24 | .tableFixHead th { 25 | position: sticky; 26 | position: -webkit-sticky; 27 | top: 0; 28 | background: #eee; 29 | } 30 | .icon-white { 31 | color: white; 32 | } 33 | .icon-black { 34 | color: black; 35 | } 36 | a:hover, a:focus { 37 | color: #428bca; 38 | outline: none; 39 | text-decoration: none; 40 | } 41 | #mainContainer { 42 | background-color: #fff; 43 | padding: 39px 3px 51px 3px; 44 | margin: 0; 45 | } 46 | .progress .progress-bar { 47 | white-space: nowrap; 48 | text-shadow:1px 1px 3px #000 49 | } 50 | h5, #detailsTrackersPage a, #detailsFilesPage a, #detailsDetailsPage #label td, .nav a, #getDirList td { 51 | word-break:break-all; 52 | } 53 | #torrentsList #list span { 54 | font-size: 12px; 55 | } 56 | 57 | 58 | /*** navbar bottom ***/ 59 | .navbar .nav > li { 60 | float: left; 61 | margin-right: 15px; 62 | } 63 | .navbar .nav > li:last-child { 64 | margin-right: 0px; 65 | } 66 | .navbar .nav > li > a, .navbar .nav > li > a:hover, .navbar .nav > li > a:focus { 67 | display: table-cell; 68 | vertical-align: middle; 69 | padding: 0; 70 | font-size: 14px; 71 | background-color: transparent; 72 | height: 50px; 73 | } 74 | .navbar .nav > li > div > span { 75 | position: relative; 76 | top: -2px; 77 | font-size: 70%; 78 | color: #fff; 79 | line-height: 0; 80 | } 81 | .navbar .nav > li > div > i { 82 | margin-top: 7px; 83 | margin-right: 2px; 84 | } 85 | .navbar .divider-vertical { 86 | height: 50px; 87 | margin: 0 15px 0 0; 88 | border-right: 1px solid #323232; 89 | border-left: 1px solid #111111; 90 | } 91 | 92 | 93 | /*** navtabs top ***/ 94 | .nav-tabs { 95 | background-color: #fff; 96 | padding: 3px 3px 0 3px; 97 | } 98 | #torrentsList .nav { 99 | white-space: nowrap; 100 | font-size: 0; 101 | } 102 | #torrentsList .nav > li > a { 103 | margin-right: 1px; 104 | } 105 | #torrentsList .nav > li > a > span { 106 | float: left; 107 | overflow: hidden; 108 | white-space: nowrap; 109 | text-overflow: ellipsis; 110 | } 111 | #torrentsList .nav > li > a > .caret { 112 | position: relative; 113 | display: inline; 114 | top: 9px; 115 | } 116 | .nav-tabs .open .dropdown-toggle { 117 | color: #fff !important; 118 | background-color: #999 !important; 119 | border-color: #999 !important; 120 | } 121 | .nav-tabs > li > a:hover, .nav-tabs > li > a:focus { 122 | background-color: transparent; 123 | border-color: transparent; 124 | } 125 | .nav-tabs #sort { 126 | float: right; 127 | } 128 | .nav-tabs #sort #sortIcon i { 129 | color: #428bca; 130 | } 131 | 132 | 133 | /*** Torrent Details ***/ 134 | #torrentDetailsHeader, #detailsTrackersPage, #detailsFilesPage { 135 | padding-top: 9px; 136 | padding-left: 8px; 137 | padding-right: 8px; 138 | } 139 | #torrentDetails #detailsDetailsPage tr td:first-child { 140 | white-space: nowrap; 141 | } 142 | #torrentDetails #detailsDetailsPage tr td:last-child { 143 | word-break: break-all; 144 | } 145 | #torrentDetails #detailsDetailsPage #label input { 146 | display: inline; 147 | height: 24px; 148 | width: 139px; 149 | padding-top: 5px; 150 | vertical-align: middle; 151 | } 152 | #torrentDetails #detailsFilesPage > div { 153 | min-height: 24px; 154 | } 155 | #torrentDetails #detailsFilesPage > div a { 156 | display: block; 157 | padding-top: 4px; 158 | } 159 | #torrentDetails #detailsFilesPage button { 160 | margin-left: 4px; 161 | } 162 | 163 | 164 | /*** Add Torrent ***/ 165 | #addTorrent { 166 | margin-top: -20px; 167 | } 168 | #addTorrent #showGetDir { 169 | height: 34px; 170 | } 171 | 172 | 173 | /*** Get Dir List ***/ 174 | #getDirList { 175 | margin-top: -20px; 176 | } 177 | #getDirList h5 { 178 | padding-left: 8px; 179 | padding-right: 8px; 180 | } 181 | #getDirList button { 182 | margin-left: 8px; 183 | margin-bottom: 15px; 184 | } 185 | #getDirList td { 186 | padding: 14px; 187 | } 188 | 189 | /*** Torrent Sort ***/ 190 | #torrentSort { 191 | margin-top: -20px; 192 | } 193 | 194 | 195 | /*** Global Settings ***/ 196 | #globalSettings { 197 | margin-top: -20px; 198 | } 199 | 200 | 201 | /*** Confirm Delete ***/ 202 | #confimTorrentDelete #confirmText { 203 | word-break: normal; 204 | } 205 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/mobile.html: -------------------------------------------------------------------------------- 1 |
2 | 3 | 39 | 40 |
41 | 77 |
78 |
79 | 80 | 149 | 150 | 162 | 163 | 173 | 174 | 207 | 208 | 209 | 210 | 215 | 216 |
217 | 218 |
219 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/plugins/mobile/plugin.info: -------------------------------------------------------------------------------- 1 | plugin.description: This plugin provides a mobile version of ruTorrent. (Not compatible with the ipad plugin) 2 | plugin.author: zebraxxl,xombiemp 3 | plugin.version: 1.0 4 | rtorrent.need: 1 5 | rtorrent.remote: warning 6 | plugin.runlevel: 15 7 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/rutorrent/settings/config.php: -------------------------------------------------------------------------------- 1 | rtorrent link through unix domain socket 34 | // (scgi_local in rtorrent conf file), change variables 35 | // above to something like this: 36 | // 37 | $scgi_port = 0; 38 | $scgi_host = "unix:////run/php/.rtorrent.sock"; 39 | 40 | $XMLRPCMountPoint = "/RPC2"; // DO NOT DELETE THIS LINE!!! DO NOT COMMENT THIS LINE!!! 41 | 42 | $pathToExternals = array( 43 | "php" => '/usr/bin/php7', // Something like /usr/bin/php. If empty, will be found in PATH. 44 | "pgrep" => '/usr/bin/pgrep', // Something like /usr/bin/pgrep. If empty, will be found in PATH. 45 | "python" => '/usr/bin/python3', // Something like /usr/bin/python3. If empty, will be found in PATH. 46 | "curl" => '/usr/bin/curl', // Something like /usr/bin/curl. If empty, will be found in PATH. 47 | "gzip" => '/usr/bin/gzip', // Something like /usr/bin/gzip. If empty, will be found in PATH. 48 | "id" => '/usr/bin/id', // Something like /usr/bin/id. If empty, will be found in PATH. 49 | "stat" => '/bin/stat', // Something like /usr/bin/stat. If empty, will be found in PATH. 50 | ); 51 | 52 | $localhosts = array( // list of local interfaces 53 | "127.0.0.1", 54 | "localhost", 55 | ); 56 | 57 | $profilePath = '/config/rutorrent/profiles'; // Path to user profiles 58 | $profileMask = 0777; // Mask for files and directory creation in user profiles. 59 | // Both Webserver and rtorrent users must have read-write access to it. 60 | // For example, if Webserver and rtorrent users are in the same group then the value may be 0770. 61 | 62 | $tempDirectory = '/config/rutorrent/profiles/tmp/'; // Temp directory. Absolute path with trail slash. If null, then autodetect will be used. 63 | 64 | $canUseXSendFile = true; // Use X-Sendfile feature if it exist 65 | 66 | $locale = "UTF8"; 67 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/rutorrent/settings/plugins.ini: -------------------------------------------------------------------------------- 1 | ;; Plugins' permissions. 2 | ;; If flag is not found in plugin section, corresponding flag from "default" section is used. 3 | ;; If flag is not found in "default" section, it is assumed to be "yes". 4 | ;; 5 | ;; For setting individual plugin permissions you must write something like that: 6 | ;; 7 | ;; [ratio] 8 | ;; enabled = yes ;; also may be "user-defined", in this case user can control plugin's state from UI 9 | ;; canChangeToolbar = yes 10 | ;; canChangeMenu = yes 11 | ;; canChangeOptions = no 12 | ;; canChangeTabs = yes 13 | ;; canChangeColumns = yes 14 | ;; canChangeStatusBar = yes 15 | ;; canChangeCategory = yes 16 | ;; canBeShutdowned = yes 17 | 18 | [default] 19 | enabled = user-defined 20 | canChangeToolbar = yes 21 | canChangeMenu = yes 22 | canChangeOptions = yes 23 | canChangeTabs = yes 24 | canChangeColumns = yes 25 | canChangeStatusBar = yes 26 | canChangeCategory = yes 27 | canBeShutdowned = yes 28 | 29 | 30 | ;; Default 31 | 32 | [_getdir] 33 | enabled = yes 34 | [_noty2] 35 | enabled = yes 36 | [_task] 37 | enabled = yes 38 | [datadir] 39 | enabled = yes 40 | [erasedata] 41 | enabled = yes 42 | [httprpc] 43 | enabled = yes 44 | canBeShutdowned = no 45 | [show_peers_like_wtorrent] 46 | enabled = yes 47 | [theme] 48 | enabled = yes 49 | 50 | ;; Enabled 51 | [autotools] 52 | enabled = user-defined 53 | [check_port] 54 | enabled = user-defined 55 | [cpuload] 56 | enabled = user-defined 57 | [create] 58 | enabled = user-defined 59 | [data] 60 | enabled = user-defined 61 | [diskspace] 62 | enabled = user-defined 63 | [edit] 64 | enabled = user-defined 65 | [extratio] 66 | enabled = user-defined 67 | [feeds] 68 | enabled = user-defined 69 | [fileshare] 70 | enabled = user-defined 71 | [fileupload] 72 | enabled = user-defined 73 | [filedrop] 74 | enabled = user-defined 75 | [geoip] 76 | enabled = user-defined 77 | [mobile] 78 | enabled = yes 79 | [ratio] 80 | enabled = user-defined 81 | [ratiocolor] 82 | enabled = user-defined 83 | [rss] 84 | enabled = user-defined 85 | [seedingtime] 86 | enabled = user-defined 87 | [screenshots] 88 | enabled = user-defined 89 | [throttle] 90 | enabled = user-defined 91 | [titlebar] 92 | enabled = user-defined 93 | [tracklabels] 94 | enabled = user-defined 95 | [trafic] 96 | enabled = user-defined 97 | [unpack] 98 | enabled = user-defined 99 | [_noty] 100 | enabled = user-defined 101 | [history] 102 | enabled = user-defined 103 | [mediainfo] 104 | enabled = user-defined 105 | [rpc] 106 | enabled = user-defined 107 | [source] 108 | enabled = user-defined 109 | 110 | ;; Disabled 111 | [nfo] 112 | enabled = no 113 | [retrackers] 114 | enabled = no 115 | [extsearch] 116 | enabled = no 117 | [spectrogram] 118 | enabled = no 119 | [mediastream] 120 | enabled = no 121 | [rssurlrewrite] 122 | enabled = no 123 | [lookat] 124 | enabled = no 125 | [instantsearch] 126 | enabled = no 127 | [ipad] 128 | enabled = no 129 | [logoff] 130 | enabled = no 131 | [loginmgr] 132 | enabled = no 133 | [filemanager] 134 | enabled = no 135 | [rutracker_check] 136 | enabled = no 137 | [scheduler] 138 | enabled = no 139 | [cookies] 140 | enabled = no 141 | [chat] 142 | enabled = no 143 | [chunks] 144 | enabled = no 145 | -------------------------------------------------------------------------------- /apps/templates/rutorrent/tasks/dynamic.yml: -------------------------------------------------------------------------------- 1 | ######################################################################### 2 | # Title: recheck the packages # 3 | # Author(s): MrDoobPG # 4 | # URL: fuuuu never # 5 | ######################################################################### 6 | # GNU General Public License v3.0 # 7 | ######################################################################### 8 | # moded from MrDoobPG for PTS # 9 | ######################################################################### 10 | - name: Update APT package cache 11 | apt: update_cache=yes cache_valid_time=600 12 | 13 | - name: Upgrade APT to the latest packages 14 | apt: upgrade=dist 15 | register: apt_result 16 | 17 | - name: Install a list of packages 18 | command: apt-get install -y jq dnsutils ctop 19 | register: apt_result 20 | changed_when: "'packages will be installed' in apt_result.stdout" 21 | 22 | - name: Autoremove unused packages 23 | command: apt-get -y autoremove 24 | register: apt_result 25 | changed_when: "'packages will be REMOVED' in apt_result.stdout" 26 | 27 | - name: Purge residual kernel packages 28 | shell: apt-get remove -y --purge $(dpkg -l | grep "^rc\s*linux-image-" | awk '{print $2}' | tr '\n' ' ') 29 | register: apt_result 30 | changed_when: "'packages will be REMOVED' in apt_result.stdout" 31 | -------------------------------------------------------------------------------- /apps/templates/sonarr/mp4_automator/autoProcess.ini: -------------------------------------------------------------------------------- 1 | [Sonarr] 2 | host = localhost 3 | port = 8989 4 | web_root = 5 | ssl = False 6 | apikey = 7 | 8 | [MP4] 9 | ffmpeg = /usr/bin/ffmpeg 10 | ffprobe = /usr/bin/ffprobe 11 | threads = auto 12 | output_directory = 13 | copy_to = 14 | move_to = 15 | output_extension = mp4 16 | output_format = mp4 17 | delete_original = True 18 | relocate_moov = True 19 | video-codec = h264,x264 20 | video-bitrate = 21 | video-crf = 22 | video-max-width = 23 | video-profile = 24 | h264-max-level = 25 | use-qsv-decoder-with-encoder = True 26 | use-hevc-qsv-decoder = False 27 | enable_dxva2_gpu_decode = False 28 | ios-audio = True 29 | ios-first-track-only = False 30 | ios-audio-filter = 31 | ios-move-last = False 32 | max-audio-channels = 33 | audio-codec = ac3 34 | audio-language = 35 | audio-default-language = 36 | audio-channel-bitrate = 37 | audio-filter = 38 | audio-copy-original = False 39 | subtitle-codec = mov_text 40 | subtitle-language = 41 | subtitle-default-language = 42 | subtitle-encoding = 43 | fullpathguess = True 44 | convert-mp4 = False 45 | tagfile = True 46 | tag-language = en 47 | download-artwork = Poster 48 | download-subs = False 49 | embed-subs = True 50 | embed-only-internal-subs = False 51 | sub-providers = addic7ed,podnapisi,thesubdb,opensubtitles 52 | permissions = 0777 53 | post-process = False 54 | pix-fmt = 55 | aac_adtstoasc = False 56 | -------------------------------------------------------------------------------- /apps/templates/sonarr/sonarr.ini: -------------------------------------------------------------------------------- 1 | [Sonarr] 2 | host = localhost 3 | port = 8989 4 | web_root = 5 | ssl = False 6 | apikey = 7 | 8 | [MP4] 9 | ffmpeg = /usr/bin/ffmpeg 10 | ffprobe = /usr/bin/ffprobe 11 | threads = auto 12 | output_directory = 13 | copy_to = 14 | move_to = 15 | output_extension = mp4 16 | output_format = mp4 17 | delete_original = True 18 | relocate_moov = True 19 | video-codec = h264,x264 20 | video-bitrate = 21 | video-crf = 22 | video-max-width = 23 | video-profile = 24 | h264-max-level = 25 | use-qsv-decoder-with-encoder = True 26 | use-hevc-qsv-decoder = False 27 | enable_dxva2_gpu_decode = False 28 | ios-audio = True 29 | ios-first-track-only = False 30 | ios-audio-filter = 31 | ios-move-last = False 32 | max-audio-channels = 33 | audio-codec = ac3 34 | audio-language = 35 | audio-default-language = 36 | audio-channel-bitrate = 37 | audio-filter = 38 | audio-copy-original = False 39 | subtitle-codec = mov_text 40 | subtitle-language = 41 | subtitle-default-language = 42 | subtitle-encoding = 43 | fullpathguess = True 44 | convert-mp4 = False 45 | tagfile = True 46 | tag-language = en 47 | download-artwork = Poster 48 | download-subs = False 49 | embed-subs = True 50 | embed-only-internal-subs = False 51 | sub-providers = addic7ed,podnapisi,thesubdb,opensubtitles 52 | permissions = 0777 53 | post-process = False 54 | pix-fmt = 55 | aac_adtstoasc = False 56 | -------------------------------------------------------------------------------- /apps/templates/sonarr4k/mp4_automator/autoProcess.ini: -------------------------------------------------------------------------------- 1 | [Sonarr] 2 | host = localhost 3 | port = 8989 4 | web_root = 5 | ssl = False 6 | apikey = 7 | 8 | [MP4] 9 | ffmpeg = /usr/bin/ffmpeg 10 | ffprobe = /usr/bin/ffprobe 11 | threads = auto 12 | output_directory = 13 | copy_to = 14 | move_to = 15 | output_extension = mp4 16 | output_format = mp4 17 | delete_original = True 18 | relocate_moov = True 19 | video-codec = h264,x264 20 | video-bitrate = 21 | video-crf = 22 | video-max-width = 23 | video-profile = 24 | h264-max-level = 25 | use-qsv-decoder-with-encoder = True 26 | use-hevc-qsv-decoder = False 27 | enable_dxva2_gpu_decode = False 28 | ios-audio = True 29 | ios-first-track-only = False 30 | ios-audio-filter = 31 | ios-move-last = False 32 | max-audio-channels = 33 | audio-codec = ac3 34 | audio-language = 35 | audio-default-language = 36 | audio-channel-bitrate = 37 | audio-filter = 38 | audio-copy-original = False 39 | subtitle-codec = mov_text 40 | subtitle-language = 41 | subtitle-default-language = 42 | subtitle-encoding = 43 | fullpathguess = True 44 | convert-mp4 = False 45 | tagfile = True 46 | tag-language = en 47 | download-artwork = Poster 48 | download-subs = False 49 | embed-subs = True 50 | embed-only-internal-subs = False 51 | sub-providers = addic7ed,podnapisi,thesubdb,opensubtitles 52 | permissions = 0777 53 | post-process = False 54 | pix-fmt = 55 | aac_adtstoasc = False 56 | -------------------------------------------------------------------------------- /apps/templates/sonarrhdr/mp4_automator/autoProcess.ini: -------------------------------------------------------------------------------- 1 | [Sonarr] 2 | host = localhost 3 | port = 8989 4 | web_root = 5 | ssl = False 6 | apikey = 7 | 8 | [MP4] 9 | ffmpeg = /usr/bin/ffmpeg 10 | ffprobe = /usr/bin/ffprobe 11 | threads = auto 12 | output_directory = 13 | copy_to = 14 | move_to = 15 | output_extension = mp4 16 | output_format = mp4 17 | delete_original = True 18 | relocate_moov = True 19 | video-codec = h264,x264 20 | video-bitrate = 21 | video-crf = 22 | video-max-width = 23 | video-profile = 24 | h264-max-level = 25 | use-qsv-decoder-with-encoder = True 26 | use-hevc-qsv-decoder = False 27 | enable_dxva2_gpu_decode = False 28 | ios-audio = True 29 | ios-first-track-only = False 30 | ios-audio-filter = 31 | ios-move-last = False 32 | max-audio-channels = 33 | audio-codec = ac3 34 | audio-language = 35 | audio-default-language = 36 | audio-channel-bitrate = 37 | audio-filter = 38 | audio-copy-original = False 39 | subtitle-codec = mov_text 40 | subtitle-language = 41 | subtitle-default-language = 42 | subtitle-encoding = 43 | fullpathguess = True 44 | convert-mp4 = False 45 | tagfile = True 46 | tag-language = en 47 | download-artwork = Poster 48 | download-subs = False 49 | embed-subs = True 50 | embed-only-internal-subs = False 51 | sub-providers = addic7ed,podnapisi,thesubdb,opensubtitles 52 | permissions = 0777 53 | post-process = False 54 | pix-fmt = 55 | aac_adtstoasc = False 56 | -------------------------------------------------------------------------------- /apps/templates/tasks/dynamic.yml: -------------------------------------------------------------------------------- 1 | - name: Update APT package cache 2 | apt: update_cache=yes cache_valid_time=600 3 | 4 | - name: Upgrade APT to the latest packages 5 | apt: upgrade=dist 6 | register: apt_result 7 | 8 | - name: Install a list of packages 9 | command: apt-get install -y jq dnsutils ctop 10 | register: apt_result 11 | changed_when: "'packages will be installed' in apt_result.stdout" 12 | 13 | - name: Autoremove unused packages 14 | command: apt-get -y autoremove 15 | register: apt_result 16 | changed_when: "'packages will be REMOVED' in apt_result.stdout" 17 | 18 | - name: Purge residual kernel packages 19 | shell: apt-get remove -y --purge $(dpkg -l | grep "^rc\s*linux-image-" | awk '{print $2}' | tr '\n' ' ') 20 | register: apt_result 21 | changed_when: "'packages will be REMOVED' in apt_result.stdout" 22 | -------------------------------------------------------------------------------- /place.holder: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/PGBlitz/Apps-Core/3307170478e03fbac23d0d5b4aed3461b57879b1/place.holder --------------------------------------------------------------------------------