diff --git a/README.md b/README.md index cedf15f..1878430 100644 --- a/README.md +++ b/README.md @@ -76,3 +76,36 @@ As an example, the cron job I use is: ``` This runs every hour on the hour + +## Running via Docker + +```bash +docker pull ghcr.io/robbrazier/readflow +``` + +### Environment Variables + +| Name | Default | Notes | +|---------------------|-------------------|---------------------------------------------------------------------------------------------------------------------| +| SOURCE | database | Leave as default - there are no other options currently | +| TARGETS | anilist,hardcover | Defaults to all targets | +| COLUMN_CHAPTER | false | Only used for Anilist - set if you want to count chapters | +| DATABASE_CALIBRE | /data/metadata.db | Mount your metadata.db here | +| DATABASE_CALIBREWEB | /data/app.db | Mount your app.db here | +| CRON_SCHEDULE | @hourly | See [crontab.guru](https://crontab.guru/#@hourly) for syntax | +| TOKEN_ANILIST | | Anilist token - Retrieve from [here](https://anilist.co/api/v2/oauth/authorize?client_id=21288&response_type=token) | +| TOKEN_HARDCOVER | | Hardcover token - Retrieve from [here](https://hardcover.app/account/api) | + +### Run modes + +#### Cron Job + +```bash +docker run -e CRON_SCHEDULE="@daily" ghcr.io/robbrazier/readflow +``` + +#### One-off Sync + +```bash +docker run ghcr.io/robbrazier/readflow sync +``` diff --git a/go.mod b/go.mod index 4c5f74d..f26f193 100644 --- a/go.mod +++ b/go.mod @@ -39,7 +39,6 @@ require ( github.com/mattn/go-isatty v0.0.20 // indirect github.com/mattn/go-localereader v0.0.1 // indirect github.com/mattn/go-runewidth v0.0.16 // indirect - github.com/mattn/go-sqlite3 v1.14.24 // indirect github.com/mitchellh/hashstructure/v2 v2.0.2 // indirect github.com/muesli/ansi v0.0.0-20230316100256-276c6243b2f6 // indirect github.com/muesli/cancelreader v0.2.2 // indirect diff --git a/go.sum b/go.sum index c9029ad..8ccee99 100644 --- a/go.sum +++ b/go.sum @@ -80,9 +80,8 @@ github.com/mattn/go-localereader v0.0.1 h1:ygSAOl7ZXTx4RdPYinUpg6W99U8jWvWi9Ye2J github.com/mattn/go-localereader v0.0.1/go.mod h1:8fBrzywKY7BI3czFoHkuzRoWE9C+EiG4R1k4Cjx5p88= github.com/mattn/go-runewidth v0.0.16 h1:E5ScNMtiwvlvB5paMFdw9p4kSQzbXFikJ5SQO6TULQc= github.com/mattn/go-runewidth v0.0.16/go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w= +github.com/mattn/go-sqlite3 v1.14.22 h1:2gZY6PC6kBnID23Tichd1K+Z0oS6nE/XwU+Vz/5o4kU= github.com/mattn/go-sqlite3 v1.14.22/go.mod h1:Uh1q+B4BYcTPb+yiD3kU8Ct7aC0hY9fxUwlHK0RXw+Y= -github.com/mattn/go-sqlite3 v1.14.24 h1:tpSp2G2KyMnnQu99ngJ47EIkWVmliIizyZBfPrBWDRM= -github.com/mattn/go-sqlite3 v1.14.24/go.mod h1:Uh1q+B4BYcTPb+yiD3kU8Ct7aC0hY9fxUwlHK0RXw+Y= github.com/mitchellh/hashstructure/v2 v2.0.2 h1:vGKWl0YJqUNxE8d+h8f6NJLcCJrgbhC4NcD46KavDd4= github.com/mitchellh/hashstructure/v2 v2.0.2/go.mod h1:MG3aRVU/N29oo/V/IhBX8GR/zz4kQkprJgF2EVszyDE= github.com/muesli/ansi v0.0.0-20230316100256-276c6243b2f6 h1:ZK8zHtRHOkbHy6Mmr5D264iyp3TiX5OmNcI5cIARiQI=