2019-07-25 18:02:25 -07:00
# Podsync

2019-11-16 00:36:38 -08:00
[](https://github.com/mxpv/podsync/actions?query=workflow%3ACI)
2023-05-05 15:47:54 -07:00
[](https://github.com/mxpv/podsync/actions/workflows/nightly.yml)
2019-11-16 00:36:38 -08:00
[](https://github.com/mxpv/podsync/releases)
2019-07-25 18:02:25 -07:00
[](https://goreportcard.com/report/github.com/mxpv/podsync)
2021-12-31 14:05:40 +02:00
[](https://github.com/sponsors/mxpv)
2019-01-07 21:09:04 -08:00
[](https://www.patreon.com/podsync)
2019-11-16 00:36:38 -08:00
[](https://twitter.com/pod_sync)
2017-08-21 23:52:02 -07:00
2019-11-13 21:14:52 -08:00
Podsync - is a simple, free service that lets you listen to any YouTube / Vimeo channels, playlists or user videos in
podcast format.
2017-08-21 23:52:02 -07:00
2019-11-13 21:14:52 -08:00
Podcast applications have a rich functionality for content delivery - automatic download of new episodes,
remembering last played position, sync between devices and offline listening. This functionality is not available
on YouTube and Vimeo. So the aim of Podsync is to make your life easier and enable you to view/listen to content on
any device in podcast client.
2017-08-21 23:52:02 -07:00
2020-03-07 18:19:46 -08:00
## Features
- Works with YouTube and Vimeo.
- Supports feeds configuration: video/ audio, high/low quality, max video height, etc.
- mp3 encoding
- Update scheduler supports cron expressions
2022-11-19 21:51:14 +02:00
- Episodes filtering (match by title, duration).
2020-03-07 22:32:51 -08:00
- Feeds customizations (custom artwork, category, language, etc).
2020-04-15 14:16:52 -07:00
- OPML export.
2020-03-07 18:19:46 -08:00
- Supports episodes cleanup (keep last X episodes).
- One-click deployment for AWS.
- Runs on Windows, Mac OS, Linux, and Docker.
- Supports ARM.
2020-04-19 13:19:31 -07:00
- Automatic youtube-dl self update.
2020-04-20 21:06:51 -07:00
- Supports API keys rotation.
2020-03-07 18:19:46 -08:00
2019-11-13 21:14:52 -08:00
## Dependencies
If you're running the CLI as binary (e.g. not via Docker), you need to make sure that dependencies are available on
2022-07-29 13:40:15 +14:00
your system. Currently, Podsync depends on `youtube-dl` , `ffmpeg` , and `go` .
2019-11-13 21:14:52 -08:00
On Mac you can install those with `brew` :
```
2022-07-29 13:40:15 +14:00
brew install youtube-dl ffmpeg go
2019-11-13 21:14:52 -08:00
```
2022-01-02 17:39:08 +02:00
## Documentation
- [How to get Vimeo API token ](./docs/how_to_get_vimeo_token.md )
- [How to get YouTube API Key ](./docs/how_to_get_youtube_api_key.md )
- [Podsync on QNAP NAS Guide ](./docs/how_to_setup_podsync_on_qnap_nas.md )
- [Schedule updates with cron ](./docs/cron.md )
2023-05-05 15:47:54 -07:00
## Nightly builds
Nightly builds uploaded every midnight from the `main` branch and available for testing:
```bash
$ docker run -it --rm ghcr.io/mxpv/podsync:nightly
```
2022-01-02 17:39:08 +02:00
### Access tokens
2019-11-13 21:14:52 -08:00
In order to query YouTube or Vimeo API you have to obtain an API token first.
2020-01-27 10:03:38 -08:00
- [How to get YouTube API key ](https://elfsight.com/blog/2016/12/how-to-get-youtube-api-key-tutorial/ )
2019-11-13 21:14:52 -08:00
- [Generate an access token for Vimeo ](https://developer.vimeo.com/api/guides/start#generate-access-token )
2022-01-02 17:31:41 +02:00
## Configuration
2019-11-13 21:14:52 -08:00
2019-12-12 11:42:00 -08:00
You need to create a configuration file (for instance `config.toml` ) and specify the list of feeds that you're going to host.
2022-01-02 17:31:41 +02:00
See [config.toml.example ](./config.toml.example ) for all possible configuration keys available in Podsync.
Minimal configuration would look like this:
2019-12-12 11:42:00 -08:00
2019-11-13 21:14:52 -08:00
```toml
[server]
port = 8080
2022-06-12 23:05:03 -04:00
[storage]
[storage.local]
data_dir = "/data/podsync/"
2019-11-13 21:14:52 -08:00
[tokens]
2022-01-02 17:31:41 +02:00
youtube = "PASTE YOUR API KEY HERE"
2019-11-13 21:14:52 -08:00
[feeds]
2022-01-02 17:31:41 +02:00
[feeds.ID1]
url = "https://www.youtube.com/channel/UCxC5Ls6DwqV0e-CYcAKkExQ"
2019-11-13 21:14:52 -08:00
```
2019-11-23 13:25:07 -08:00
If you want to hide Podsync behind reverse proxy like nginx, you can use `hostname` field:
```toml
[server]
port = 8080
hostname = "https://my.test.host:4443"
[feeds]
[feeds.ID1]
...
```
2020-02-08 17:00:39 -08:00
Server will be accessible from `http://localhost:8080` , but episode links will point to `https://my.test.host:4443/ID1/...`
2019-12-13 19:30:36 -08:00
## One click deployment
[](https://console.aws.amazon.com/cloudformation/home?region=us-west-1#/stacks/new ?stackName=Podsync& templateURL=https://podsync-cf.s3.amazonaws.com/cloud_formation.yml)
2019-11-13 21:14:52 -08:00
## How to run
2022-06-24 00:26:47 +02:00
### Build and run as binary:
Make sure you have created the file `config.toml` . Also note the location of the `data_dir` . Depending on the operating system, you may have to choose a different location since `/app/data` might be not writable.
2019-11-13 21:14:52 -08:00
```
2022-06-24 00:26:47 +02:00
$ git clone https://github.com/mxpv/podsync
$ cd podsync
$ make
$ ./bin/podsync --config config.toml
2019-11-13 21:14:52 -08:00
```
2022-06-24 00:26:47 +02:00
### How to debug
Use the editor [Visual Studio Code ](https://code.visualstudio.com/ ) and install the official [Go ](https://marketplace.visualstudio.com/items?itemName=golang.go ) extension. Afterwards you can execute "Run & Debug" ▶︎ "Debug Podsync" to debug the application. The required configuration is already prepared (see `.vscode/launch.json` ).
2020-02-09 02:51:30 +03:00
### Run via Docker:
2019-11-13 21:14:52 -08:00
```
$ docker pull mxpv/podsync:latest
$ docker run \
-p 8080:8080 \
-v $(pwd)/data:/app/data/ \
-v $(pwd)/config.toml:/app/config.toml \
mxpv/podsync:latest
```
2020-02-09 02:51:30 +03:00
### Run via Docker Compose:
2019-11-13 21:14:52 -08:00
```
$ docker-compose up
```
## How to make a release
2019-11-13 20:43:47 -08:00
2020-04-13 17:33:03 -07:00
Just push a git tag. CI will do the rest.