add plex
This commit is contained in:
parent
90b904595a
commit
6fac939363
8
hosts
8
hosts
|
@ -40,6 +40,13 @@ all:
|
||||||
bastion:
|
bastion:
|
||||||
ansible_host: 192.168.20.10
|
ansible_host: 192.168.20.10
|
||||||
users_enable_sudo: false
|
users_enable_sudo: false
|
||||||
|
plex:
|
||||||
|
hosts:
|
||||||
|
plex:
|
||||||
|
ansible_host: 192.168.20.31
|
||||||
|
nfs_libraries:
|
||||||
|
- 192.168.20.30:/mnt/pool0/badjware/Videos/Movies
|
||||||
|
- 192.168.20.30:/mnt/pool0/badjware/Videos/Series
|
||||||
k3s:
|
k3s:
|
||||||
children:
|
children:
|
||||||
k3s-server:
|
k3s-server:
|
||||||
|
@ -72,5 +79,6 @@ all:
|
||||||
proxmox:
|
proxmox:
|
||||||
bastions:
|
bastions:
|
||||||
k3s:
|
k3s:
|
||||||
|
plex:
|
||||||
vars:
|
vars:
|
||||||
<<: *user_config
|
<<: *user_config
|
|
@ -16,4 +16,8 @@
|
||||||
- k3s-server
|
- k3s-server
|
||||||
- hosts: k3s-agent
|
- hosts: k3s-agent
|
||||||
roles:
|
roles:
|
||||||
- k3s-agent
|
- k3s-agent
|
||||||
|
|
||||||
|
- hosts: plex
|
||||||
|
roles:
|
||||||
|
- plex
|
|
@ -10,6 +10,7 @@
|
||||||
- curl
|
- curl
|
||||||
- vim
|
- vim
|
||||||
- tmux
|
- tmux
|
||||||
|
- gpg
|
||||||
|
|
||||||
- name: Set default editor to vim
|
- name: Set default editor to vim
|
||||||
lineinfile:
|
lineinfile:
|
||||||
|
|
|
@ -0,0 +1 @@
|
||||||
|
nfs_libraries: []
|
|
@ -0,0 +1,31 @@
|
||||||
|
- name: Add plex package repository key
|
||||||
|
ansible.builtin.apt_key:
|
||||||
|
url: https://downloads.plex.tv/plex-keys/PlexSign.key
|
||||||
|
|
||||||
|
- name: Add plex package repository
|
||||||
|
apt_repository:
|
||||||
|
repo: deb https://downloads.plex.tv/repo/deb public main
|
||||||
|
|
||||||
|
- name: Install packages
|
||||||
|
apt:
|
||||||
|
update_cache: yes
|
||||||
|
name:
|
||||||
|
- gpg
|
||||||
|
- plexmediaserver
|
||||||
|
- nfs-common
|
||||||
|
|
||||||
|
- name: Create library mount points
|
||||||
|
file:
|
||||||
|
path: "/mnt/{{ item|regex_replace(':','/') }}"
|
||||||
|
state: directory
|
||||||
|
loop: '{{ nfs_libraries }}'
|
||||||
|
|
||||||
|
- name: Create library mount points
|
||||||
|
mount:
|
||||||
|
boot: yes
|
||||||
|
path: "/mnt/{{ item|regex_replace(':','/') }}"
|
||||||
|
src: "{{ item }}"
|
||||||
|
fstype: nfs
|
||||||
|
opts: defaults,ro,_netdev
|
||||||
|
state: mounted
|
||||||
|
loop: '{{ nfs_libraries }}'
|
Loading…
Reference in New Issue