Add a script to rebuild the feeds if redis fails
This commit is contained in:
@@ -39,6 +39,16 @@
|
|||||||
dest: /home/mastodon/live/docker-compose.yml
|
dest: /home/mastodon/live/docker-compose.yml
|
||||||
notify: "docker-compose up"
|
notify: "docker-compose up"
|
||||||
|
|
||||||
|
- name: Install feed rebuild script
|
||||||
|
template:
|
||||||
|
src: feeds-build.sh.j2
|
||||||
|
dest: /usr/local/bin/feeds-build.sh
|
||||||
|
|
||||||
|
- name: Set permission of feeds-build.sh
|
||||||
|
file:
|
||||||
|
path: /usr/local/bin/feeds-build.sh
|
||||||
|
mode: '0755'
|
||||||
|
|
||||||
- import_tasks: redis.yml
|
- import_tasks: redis.yml
|
||||||
when: ansible_hostname == REDIS_HOST
|
when: ansible_hostname == REDIS_HOST
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,4 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# If we run this from cron, remove change to "docker exec -i" as we don't have an attached terminal
|
||||||
|
docker exec -it live-web-1 bin/tootctl feeds build --all
|
||||||
Reference in New Issue
Block a user