Miniflux: install and configure rss reader
This commit is contained in:
25
files/miniflux/backup.sh.j2
Normal file
25
files/miniflux/backup.sh.j2
Normal file
@ -0,0 +1,25 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
set -eu
|
||||
set -o pipefail
|
||||
|
||||
TIMESTAMP=$(date +%Y%m%d_%H%M%S)
|
||||
BACKUP_FILE="miniflux_postgres_${TIMESTAMP}.sql.gz"
|
||||
|
||||
echo "miniflux: backing up postgresql database"
|
||||
|
||||
docker compose --file "{{ base_dir }}/docker-compose.yml" exec \
|
||||
miniflux_postgres \
|
||||
pg_dump \
|
||||
-U "{{ miniflux_postgres_user }}" \
|
||||
"{{ miniflux_postgres_database }}" \
|
||||
| gzip > "{{ postgres_backups_dir }}/${BACKUP_FILE}"
|
||||
|
||||
echo "miniflux: PostgreSQL backup saved to {{ postgres_backups_dir }}/${BACKUP_FILE}"
|
||||
|
||||
echo "miniflux: removing old backups"
|
||||
|
||||
# Keep only the 3 most recent backups
|
||||
keep-files.py "{{ postgres_backups_dir }}" --keep 3
|
||||
|
||||
echo "miniflux: backup completed successfully."
|
52
files/miniflux/docker-compose.yml.j2
Normal file
52
files/miniflux/docker-compose.yml.j2
Normal file
@ -0,0 +1,52 @@
|
||||
# See sample https://miniflux.app/docs/docker.html#docker-compose
|
||||
# See env https://miniflux.app/docs/configuration.html
|
||||
|
||||
services:
|
||||
miniflux_app:
|
||||
image: miniflux/miniflux:2.2.10
|
||||
container_name: miniflux_app
|
||||
depends_on:
|
||||
miniflux_postgres:
|
||||
condition: service_healthy
|
||||
networks:
|
||||
- "miniflux_network"
|
||||
- "{{ web_proxy_network }}"
|
||||
environment:
|
||||
- DATABASE_URL=postgres://{{ miniflux_postgres_user }}:{{ miniflux_postgres_password }}@miniflux_postgres/{{ miniflux_postgres_database }}?sslmode=disable
|
||||
- RUN_MIGRATIONS=1
|
||||
- CREATE_ADMIN=1
|
||||
- ADMIN_USERNAME={{ miniflux_admin_user }}
|
||||
- ADMIN_PASSWORD={{ miniflux_admin_password }}
|
||||
- BASE_URL=https://miniflux.vakhrushev.me
|
||||
- DISABLE_LOCAL_AUTH=1
|
||||
- OAUTH2_OIDC_DISCOVERY_ENDPOINT=https://auth.vakhrushev.me
|
||||
- OAUTH2_CLIENT_ID={{ miniflux_oidc_client_id }}
|
||||
- OAUTH2_CLIENT_SECRET={{ miniflux_oidc_client_secret }}
|
||||
- OAUTH2_OIDC_PROVIDER_NAME=Authelia
|
||||
- OAUTH2_PROVIDER=oidc
|
||||
- OAUTH2_REDIRECT_URL=https://miniflux.vakhrushev.me/oauth2/oidc/callback
|
||||
- OAUTH2_USER_CREATION=1
|
||||
- METRICS_COLLECTOR=1
|
||||
- METRICS_ALLOWED_NETWORKS=0.0.0.0/0
|
||||
|
||||
miniflux_postgres:
|
||||
image: postgres:16.3-bookworm
|
||||
container_name: miniflux_postgres
|
||||
environment:
|
||||
- POSTGRES_USER={{ miniflux_postgres_user }}
|
||||
- POSTGRES_PASSWORD={{ miniflux_postgres_password }}
|
||||
- POSTGRES_DB={{ miniflux_postgres_database }}
|
||||
networks:
|
||||
- "miniflux_network"
|
||||
volumes:
|
||||
- {{ postgres_data_dir }}:/var/lib/postgresql/data
|
||||
healthcheck:
|
||||
test: ["CMD", "pg_isready", "-U", "miniflux"]
|
||||
interval: 10s
|
||||
start_period: 30s
|
||||
|
||||
networks:
|
||||
miniflux_network:
|
||||
driver: bridge
|
||||
{{ web_proxy_network }}:
|
||||
external: true
|
Reference in New Issue
Block a user