Compare commits

...

10 Commits

19 changed files with 143 additions and 160 deletions

View File

@ -1,8 +0,0 @@
---
MEDIA_FOLDER: /mnt/media
CONFIG_FOLDER: /mnt/apps
DOWNLOADS_FOLDER: /mnt/media/downloads
TZ: America/New_York
PUID: 1000
PGID: 1000

View File

@ -0,0 +1,4 @@
---
TZ: "America/New_York"
PUID: 1000
PGID: 1000

View File

@ -30,5 +30,8 @@
image: containrrr/watchtower
restart_policy: always
command: --schedule "0 0 4 * * *"
env:
- "TZ={{ TZ }}"
- WATCHTOWER_CLEANUP=true
volumes:
- /var/run/docker.sock:/var/run/docker.sock

View File

@ -4,7 +4,7 @@
apt:
name:
- qemu-guest-agent
update_cache: yes
update_cache: true
state: present
- include_tasks: docker.yml

View File

@ -1,2 +0,0 @@
---
# vars file for base

View File

@ -1,6 +1,6 @@
galaxy_info:
author: your name
description: your role description
author: Ryan Goodwin
description: Install home service
company: your company (optional)
# If the issue tracker for your role is not on github, uncomment the
@ -16,7 +16,7 @@ galaxy_info:
# - CC-BY-4.0
license: license (GPL-2.0-or-later, MIT, etc)
min_ansible_version: 2.1
min_ansible_version: "2.1"
# If this a Container Enabled role, provide the minimum Ansible Container version.
# min_ansible_container_version:
@ -26,18 +26,8 @@ galaxy_info:
# If you don't wish to enumerate all versions for a particular platform, use 'all'.
# To view available platforms and versions (or releases), visit:
# https://galaxy.ansible.com/api/v1/platforms/
#
# platforms:
# - name: Fedora
# versions:
# - all
# - 25
# - name: SomePlatform
# versions:
# - all
# - 1.0
# - 7
# - 99.99
platforms:
- name: Ubuntu
galaxy_tags: []
# List tags for your role here, one per line. A tag is a keyword that describes

View File

@ -55,3 +55,17 @@
- 8080:80
- 8081:81
- 4443:443
- name: Deploy Librespeed
community.docker.docker_container:
name: librespeed
image: ghcr.io/linuxserver/librespeed:latest
restart_policy: unless-stopped
env:
- "TZ={{ TZ }}"
- "PUID={{ PUID }}"
- "PGID={{ PGID }}"
volumes:
- "{{ CONFIG_FOLDER }}/librespeed/config:/config"
ports:
- 8505:80

View File

@ -1,2 +0,0 @@
---
# vars file for home-apps

View File

@ -1,38 +1,69 @@
Role Name
=========
Media Manager
=============
A brief description of the role goes here.
Requirements
------------
Any pre-requisites that may not be covered by Ansible itself or the role should be mentioned here. For instance, if the role uses the EC2 module, it may be a good idea to mention in this section that the boto package is required.
A series of docker containers to allow full automation of media management.
Role Variables
--------------
A description of the settable variables for this role should go here, including any variables that are in defaults/main.yml, vars/main.yml, and any variables that can/should be set via parameters to the role. Any variables that are read from other roles and/or the global scope (ie. hostvars, group vars, etc.) should be mentioned here as well.
| Variable | Description | Required | Default |
| -------------------- | --------------------------------------------------- | :------: | ------- |
| `TZ` | Timezone | - [ ] | `America/New_York` |
| `PUID` | User ID | - [ ] | `1000` |
| `PGID` | Group ID | - [ ] | `1000` |
| `PIA_USER` | username for PIA VPN | - [x] | |
| `PIA_PASS` | password for PIA VPN | - [x] | |
| `DOWNLOAD_FOLDER` | Folder where completed torrents are downloaded | - [ ] | `/mnt/downloads` |
| `CONFIG_FOLDER` | Folder containing all persistent configuration data | - [ ] | `~/.config` |
| `MEDIA_FOLDER` | base folder for all media content | - [ ] | `/mnt/media` |
| `MOVIE_FOLDER` | folder for 1080p movies | - [ ] | `{{ MEDIA_FOLDER }}/movies` |
| `MOVIE_ANIME_FOLDER` | folder for anime movies | - [ ] | `{{ MEDIA_FOLDER }}/movies-anime` |
| `MOVIE_4k_FOLDER` | folder for movies in 4k | - [ ] | `{{ MEDIA_FOLDER }}/movies-4k` |
| `TV_FOLDER` | folder for TV Shows 1080p or lower | - [ ] | `{{ MEDIA_FOLDER }}/tv` |
| `TV_ANIME_FOLDER` | folder for Anime TV Shows | - [ ] | `{{ MEDIA_FOLDER }}/tv-anime` |
| `TV_4K_FOLDER` | folder for TV Shows in 4k | - [ ] | `{{ MEDIA_FOLDER }}/tv-4k` |
Dependencies
------------
A list of other roles hosted on Galaxy should go here, plus any details in regards to parameters that may need to be set for other roles, or variables that are used from other roles.
* Docker module
Example Playbook
----------------
Including an example of how to use your role (for instance, with variables passed in as parameters) is always nice for users too:
Required vars
```yaml
- hosts: media-managers
include_roles:
- name: media-manager
vars:
PIA_USER: "username-here"
PIA_PASS: "password-here"
```
- hosts: servers
roles:
- { role: username.rolename, x: 42 }
All variables
```yaml
- hosts: media-managers
include_roles:
- name: media-manager
vars:
PIA_USER: "username-here"
PIA_PASS: "password-here"
TZ: "America/New_York"
PUID: "1000"
PGID: "1000"
DOWNLOAD_FOLDER: "/mnt/downloads"
CONFIG_FOLDER: "~/.config"
MEDIA_FOLDER: "/mnt/content"
MOVIE_FOLDER: "/mnt/content/movies"
MOVIE_4K_FOLDER: "/mnt/content/movies-4k"
MOVIE_ANIME_FOLDER: "/mnt/content/movies-anime"
TV_FOLDER: "/mnt/content/tv"
TV_4K_FOLDER: "/mnt/content/tv-4k"
TV_ANIME_FOLDER: "/mnt/content/tv-anime"
```
License
-------
BSD
Author Information
------------------
An optional section for the role authors to include contact information, or a website (HTML is not allowed).

View File

@ -1,2 +1,15 @@
---
# defaults file for media-manager
TZ: "America/New_York"
PUID: 1000
PGID: 1000
DOWNLOAD_FOLDER: "/mnt/downloads"
CONFIG_FOLDER: "~/.config/"
MEDIA_FOLDER: "/mnt/content"
MOVIE_FOLDER: "{{ MEDIA_FOLDER }}/movies"
MOVIE_ANIME_FOLDER: "{{ MEDIA_FOLDER }}/movies-anime"
MOVIE_4K_FOLDER: "{{ MEDIA_FOLDER }}/movies-4k"
TV_FOLDER: "{{ MEDIA_FOLDER }}/tv"
TV_ANIME_FOLDER: "{{ MEDIA_FOLDER }}/tv-anime"
TV_4K_FOLDER: "{{ MEDIA_FOLDER }}/tv-4k"

View File

@ -14,13 +14,15 @@
restart_policy: unless-stopped
env:
- "TZ={{ TZ }}"
- "OPENVPN_PROVIDER: PIA"
- "OPENVPN_CONFIG: ca_toronto"
- "OPENVPN_USERNAME: {{ PIA_USER }}"
- "OPENVPN_PASSWORD: {{ PIA_PASS }}"
- "LOCAL_NETWORK: 192.168.0.0/24"
- OPENVPN_PROVIDER=PIA
- OPENVPN_CONFIG=ca_toronto
- "OPENVPN_USERNAME={{ PIA_USER }}"
- "OPENVPN_PASSWORD={{ PIA_PASS }}"
- LOCAL_NETWORK=192.168.0.0/24
volumes:
- "{{ CONFIG_FOLDER }}/transmission/data:/data"
ports:
- 9091:9091
capabilities:
- NET_ADMIN
@ -106,23 +108,6 @@
ports:
- 7878:7878
- name: Deploy Radarr
community.docker.docker_container:
name: radarr
image: lscr.io/linuxserver/radarr
restart_policy: unless-stopped
env:
- "TZ={{ TZ }}"
- "PUID={{ PUID }}"
- "PGID={{ PGID }}"
volumes:
- "{{ CONFIG_FOLDER }}/radarr/config:/config"
- "{{ DOWNLOAD_FOLDER }}:/downloads"
- "{{ MOVIE_FOLDER }}:/movie"
- "{{ MOVIE_ANIME_FOLDER }}:/movie-anime"
ports:
- 8787:7878
- name: Deploy Radarr 4k
community.docker.docker_container:
name: radarr
@ -135,10 +120,39 @@
volumes:
- "{{ CONFIG_FOLDER }}/radarr/config:/config"
- "{{ DOWNLOAD_FOLDER }}:/downloads"
- "{{ MOVIE_4k_FOLDER }}:/movie"
- "{{ MOVIE_4K_FOLDER }}:/movie"
ports:
- 8787:7878
# Distributable Transcoding Server
- name: Deploy Tdarr
community.docker.docker_container:
name: tdarr-server
image: ghcr.io/haveagitgat/tdarr
restart_policy: unless-stopped
network_mode: bridge
env:
- "TZ={{ TZ }}"
- "PUID={{ PUID }}"
- "PGID={{ PGID }}"
- serverIP=0.0.0.0
- webUIPort=8265
- serverPort=8266
- internalNode=true
- nodeId=ServerNode
- NVIDIA_DRIVER_CAPABILITIES=all
- NVIDIA_VISIBLE_DEVICES=all
volumes:
- "{{ CONFIG_FOLDER }}/tdarr-server/server:/app/server"
- "{{ CONFIG_FOLDER }}/tdarr-server/config:/app/config"
- "{{ CONFIG_FOLDER }}/tdarr-server/logs:/app/logs"
- "{{ MEDIA_FOLDER }}:/content"
- /temp:/temp
ports:
- 8265:8265
- 8266:8266
# Music Manager
- name: Deploy Lidarr
community.docker.docker_container:
@ -166,7 +180,7 @@
- "TZ={{ TZ }}"
- "PUID={{ PUID }}"
- "PGID={{ PGID }}"
- "LOG_LEVEL=INFO"
- LOG_LEVEL=INFO
volumes:
- "{{ CONFIG_FOLDER }}/overseerr/config:/config"
ports:
@ -187,6 +201,19 @@
ports:
- 4545:4545
- name: Deploy Plex
community.docker.docker_container:
name: plex
image: lscr.io/linuxserver/plex
restart_policy: always
env:
- "PUID={{ PUID }}"
- "PGID={{ PGID }}"
- VERSION=docker
volumes:
- "{{ CONFIG_FOLDER }}/plex/config:/config"
- "{{ MEDIA_FOLDER }}:/content"
# Custom TV Channels
- name: Deploy disquetv
community.docker.docker_container:

View File

@ -1,2 +0,0 @@
---
# vars file for media-manager

View File

@ -1,38 +0,0 @@
Role Name
=========
A brief description of the role goes here.
Requirements
------------
Any pre-requisites that may not be covered by Ansible itself or the role should be mentioned here. For instance, if the role uses the EC2 module, it may be a good idea to mention in this section that the boto package is required.
Role Variables
--------------
A description of the settable variables for this role should go here, including any variables that are in defaults/main.yml, vars/main.yml, and any variables that can/should be set via parameters to the role. Any variables that are read from other roles and/or the global scope (ie. hostvars, group vars, etc.) should be mentioned here as well.
Dependencies
------------
A list of other roles hosted on Galaxy should go here, plus any details in regards to parameters that may need to be set for other roles, or variables that are used from other roles.
Example Playbook
----------------
Including an example of how to use your role (for instance, with variables passed in as parameters) is always nice for users too:
- hosts: servers
roles:
- { role: username.rolename, x: 42 }
License
-------
BSD
Author Information
------------------
An optional section for the role authors to include contact information, or a website (HTML is not allowed).

View File

@ -1,2 +0,0 @@
---
# defaults file for media

View File

@ -1,2 +0,0 @@
---
# handlers file for media

View File

@ -1,28 +0,0 @@
galaxy_info:
author: Ryan Goodwin
description: Deploy container for media server
license: MIT
min_ansible_version: "2.1"
# Provide a list of supported platforms, and for each platform a list of versions.
# If you don't wish to enumerate all versions for a particular platform, use 'all'.
# To view available platforms and versions (or releases), visit:
# https://galaxy.ansible.com/api/v1/platforms/
platforms:
- name: Ubuntu
versions:
- focal
galaxy_tags: []
# List tags for your role here, one per line. A tag is a keyword that describes
# and categorizes the role. Users find roles by searching for tags. Be sure to
# remove the '[]' above, if you add tags to this list.
#
# NOTE: A tag is limited to a single word comprised of alphanumeric characters.
# Maximum 20 tags per role.
dependencies: []
# List your role dependencies here, one per line. Be sure to remove the '[]' above,
# if you add dependencies to this list.

View File

@ -1,13 +0,0 @@
---
- name: Deploy Plex
community.docker.docker_container:
name: plex
image: lscr.io/linuxserver/plex
restart_policy: unless-stopped
env:
- "PUID={{ PUID }}"
- "PGID={{ PGID }}"
- "VERSION=docker"
volumes:
- "{{ CONFIG_FOLDER }}/plex/config:/config"
- "{{ MEDIA_FOLDER }}:/content"

View File

@ -1,2 +0,0 @@
---
# vars file for media

View File

@ -135,7 +135,7 @@ resource "proxmox_vm_qemu" "media-manager" {
resource "proxmox_vm_qemu" "pi_hole" {
count = 1
name = "pihole-${count.index + 1}"
name = "pihole"
vmid = "202"
target_node = "recyclebin"
clone = var.base_image