From b5d676b6fe58bee67bec361ec7d1b5847661b525 Mon Sep 17 00:00:00 2001 From: Jake Howard Date: Wed, 25 Nov 2020 13:00:06 +0000 Subject: [PATCH] Install fever plugin for tt-rss Had to chown the directory afterwards, as git wouldn't play nice with `become_user` --- .../files/tt-rss/docker-compose.yml | 1 + .../roles/intersect_docker/tasks/tt-rss.yml | 27 ++++++++++++++++++- 2 files changed, 27 insertions(+), 1 deletion(-) diff --git a/ansible/roles/intersect_docker/files/tt-rss/docker-compose.yml b/ansible/roles/intersect_docker/files/tt-rss/docker-compose.yml index 4d10baf..ef8bf12 100644 --- a/ansible/roles/intersect_docker/files/tt-rss/docker-compose.yml +++ b/ansible/roles/intersect_docker/files/tt-rss/docker-compose.yml @@ -10,6 +10,7 @@ services: volumes: - "{{ app_data_dir }}/tt-rss/config.php:/config/config.php:ro" - "{{ app_data_dir }}/tt-rss/feed-icons:/config/feed-icons" + - ./plugins:/config/plugins.local restart: unless-stopped labels: - traefik.enable=true diff --git a/ansible/roles/intersect_docker/tasks/tt-rss.yml b/ansible/roles/intersect_docker/tasks/tt-rss.yml index a8c550d..f538f15 100644 --- a/ansible/roles/intersect_docker/tasks/tt-rss.yml +++ b/ansible/roles/intersect_docker/tasks/tt-rss.yml @@ -6,6 +6,15 @@ mode: "{{ docker_compose_directory_mask }}" become: true +- name: Create tt-rss plugins directory + file: + path: /opt/tt-rss/plugins + state: directory + owner: "{{ docker_user.name }}" + mode: "{{ docker_compose_directory_mask }}" + register: plugins_dir + become: true + - name: Install tt-rss compose file template: src: files/tt-rss/docker-compose.yml @@ -25,8 +34,24 @@ register: config_file become: true +- name: Install fever plugin + git: + repo: https://github.com/DigitalDJ/tinytinyrss-fever-plugin + dest: "{{ plugins_dir.path }}/fever" + depth: 1 + register: fever_plugin + become: true + +- name: Ensure plugins are owned by {{ docker_user.name }} + file: + path: "{{ plugins_dir.path }}" + state: directory + owner: "{{ docker_user.name }}" + recurse: true + become: true + - name: restart tt-rss shell: chdir: /opt/tt-rss cmd: "{{ docker_update_command }}" - when: compose_file.changed or config_file.changed + when: compose_file.changed or config_file.changed or fever_plugin.changed