Simplify music roles : only installation, download and import

master
Quentin Duchemin 2021-05-12 17:15:08 +02:00
parent 410ce50a59
commit dfe55a71a8
Signed by: Chosto
GPG Key ID: 0547178FEEDE7D6B
4 changed files with 26 additions and 32 deletions

View File

@ -2,14 +2,8 @@
- hosts: all
become: yes
tasks:
- name: Download and configure deezloader and beets
include_role:
name: music
tasks_from: download_music_requirements
apply:
tags: requirements
tags: requirements
- name: Install and configure Funkwhale
- name: Install and configure Funkwhale, deezloader and beets
include_role:
name: music
tasks_from: funkwhale

View File

@ -1,25 +0,0 @@
- name: Install deezloader and beets
pip:
name: "{{ item }}"
state: present
loop:
- deezloader
- beets
- name: Create deezloader and beets directories
file:
path: "{{ item }}"
state: directory
owner: "{{ base_user_name }}"
group: "{{ base_user_name }}"
mode: 0755
recurse: yes
loop:
- "{{ deezloader_folder_path }}"
- "{{ deezloader_songs_path }}"
- "{{ beets_config_folder }}"
- name: Update beets configuration file
template:
src: beets_config.yaml.j2
dest: "{{ beets_config_folder }}/config.yaml"

View File

@ -1,4 +1,25 @@
---
- name: Install deezloader and beets
pip:
name: "{{ item }}"
state: present
loop:
- deezloader
- beets
- name: Create deezloader and beets directories
file:
path: "{{ item }}"
state: directory
owner: "{{ base_user_name }}"
group: "{{ base_user_name }}"
mode: 0755
recurse: yes
loop:
- "{{ deezloader_folder_path }}"
- "{{ deezloader_songs_path }}"
- "{{ beets_config_folder }}"
- name: Create Funkwhale directory
file:
path: "{{ funkwhale_folder_name }}"

View File

@ -0,0 +1,4 @@
- name: Update beets configuration file
template:
src: beets_config.yaml.j2
dest: "{{ beets_config_folder }}/config.yaml"