Skip to content

Monitor YouTube channels using RSS feeds, and add new videos to a collection in Raindrop.io.

License

Notifications You must be signed in to change notification settings

thevops/youtube-tracker

Repository files navigation

YouTube Tracker

Monitor YouTube channels using RSS feeds, and add new videos to a collection in Raindrop.io.

The application runs in a loop, checking for new videos every X minutes (frequency). Each run will add new videos uploaded since the last run (the cache file contains video IDs from the previous run).

🎁 Features

  • Monitor multiple YouTube channels
  • Add new videos to a Raindrop.io collection
  • Configurable check frequency
  • Caching of previously processed videos

📝 Prerequisites

  • Docker
  • Docker Compose
  • Bun (JavaScript runtime; drop-in replacement for Node.js)
  • Raindrop.io account

🛠️ Installation

  1. Clone the repository:
git clone https://github.com/thevops/youtube-tracker
cd youtube-tracker
  1. Copy the configuration template and edit it:
cp config/_template.yaml config/production.yaml
# Edit config/production.yaml with your preferred settings
  1. Build and start the application using Docker Compose:
docker compose build
docker compose up -d

🧾 Configuration

The configuration file is located at config/production.yaml. Here is an example configuration:

log_level: info
frequency: 30 # minutes
raindrop_token: "your_raindrop_token"
raindrop_collection_id: "your_collection_id"
cache_file_path: "/data/cache.json"
feeds:
  - name: DevOpsToolkit
    channel_id: UCfz8x0lVzJpb_dgWm9kPVrw
  - name: Mateusz Chrobok
    channel_id: UCTTZqMWBvLsUYqYwKTdjvkw
  # Add more channels as needed

🧪 Development

To start the application for local development:

bun src/index.ts config/production.yaml

To run a single script:

bun <script_name>

./src/youtube.ts file can be executed separately to test the YouTube functionality. When running the script in this way, the configuration file is not required. For more details, see the script's if (import.meta.main) {} block.

📦 Building the Docker Image

To build the Docker image:

docker buildx build --platform linux/arm64 -t local/youtube-tracker .

🧽 Formatting Code

To format the code using Prettier:

bun x prettier --write .

License

This project is licensed under the MIT License.

About

Monitor YouTube channels using RSS feeds, and add new videos to a collection in Raindrop.io.

Topics

Resources

License

Stars

Watchers

Forks

Packages