Skip to content

Commit

Permalink
Add docker compose file for testing
Browse files Browse the repository at this point in the history
  • Loading branch information
mgnsk committed Oct 25, 2024
1 parent 25ef23f commit 010425d
Show file tree
Hide file tree
Showing 2 changed files with 59 additions and 0 deletions.
21 changes: 21 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ A FreshRSS extension for automatic feed refresh TTL based on the average frequen
It dynamically adjusts the update TTL of feeds which use the default TTL option.

# Configuration

The main configurable value is the max TTL.
Feeds that use the default TTL are updated at an interval between the default and max TTL.
It is recommended to configure max TTL to be greater than default TTL.
Expand All @@ -14,3 +15,23 @@ depending on the average frequency of entries.
When a feed becomes idle (the last entry is more than 2x max TTL ago), the feed will fall back to be updated once every max TTL until the feed becomes active again.

![Screenshot 2024-10-17 at 16-42-11 AutoTTL · Extensions · FreshRSS](https://github.com/user-attachments/assets/ba712811-d65b-4cd7-ba91-c8cba5c40d64)

# Testing

Run `docker compose up` and open browser at `http://localhost:8080`.

## MySQL credentials

Host: `mysql`
Username: `freshrss`
Password: `freshrss`
Database: `freshrss`

## PostgreSQL credentials

Host: `postgres`
Username: `freshrss`
Password: `freshrss`
Database: `freshrss`

To reset, run `docker compose down`.
38 changes: 38 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
---
services:
mysql:
image: mysql
restart: unless-stopped
environment:
MYSQL_ROOT_PASSWORD: root
MYSQL_USER: freshrss
MYSQL_PASSWORD: freshrss
MYSQL_DATABASE: freshrss
tmpfs:
- /var/lib/mysql:uid=999,gid=999

postgres:
image: postgres
environment:
POSTGRES_PASSWORD: freshrss
POSTGRES_USER: freshrss
POSTGRES_DB: freshrss
tmpfs:
- /var/lib/postgresql:uid=999,gid=999

freshrss:
image: freshrss/freshrss:latest
container_name: freshrss
hostname: freshrss
restart: unless-stopped
logging:
options:
max-size: 10m
volumes:
- .:/var/www/FreshRSS/extensions/FreshRSS-AutoTTL
environment:
CRON_MIN: '*'
TRUSTED_PROXY: 172.16.0.1/12 192.168.0.1/16
FRESHRSS_ENV: development
ports:
- "8080:80"

0 comments on commit 010425d

Please sign in to comment.