Skip to content

Commit 37856a7

Browse files
Configure minimum permitted video height with VIDEO_HEIGHT_CUTOFF env
var
1 parent 30d2b68 commit 37856a7

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -368,13 +368,14 @@ useful if you are manually installing TubeSync in some other environment. These
368368
| TUBESYNC_DEBUG | Enable debugging | True |
369369
| TUBESYNC_WORKERS | Number of background workers, default is 2, max allowed is 8 | 2 |
370370
| TUBESYNC_HOSTS | Django's ALLOWED_HOSTS, defaults to `*` | tubesync.example.com,otherhost.com |
371-
| TUBESYNC_RESET_DOWNLOAD_DIR | Toggle resetting `/downloads` permissions, defaults to True | True
371+
| TUBESYNC_RESET_DOWNLOAD_DIR | Toggle resetting `/downloads` permissions, defaults to True | True |
372372
| GUNICORN_WORKERS | Number of gunicorn workers to spawn | 3 |
373373
| LISTEN_HOST | IP address for gunicorn to listen on | 127.0.0.1 |
374374
| LISTEN_PORT | Port number for gunicorn to listen on | 8080 |
375375
| HTTP_USER | Sets the username for HTTP basic authentication | some-username |
376376
| HTTP_PASS | Sets the password for HTTP basic authentication | some-secure-password |
377377
| DATABASE_CONNECTION | Optional external database connection details | mysql://user:pass@host:port/database |
378+
| VIDEO_HEIGHT_CUTOFF | Smallest video height in pixels permitted to download | 240 |
378379

379380

380381
# Manual, non-containerised, installation

tubesync/tubesync/settings.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -150,8 +150,8 @@
150150
MEDIA_THUMBNAIL_HEIGHT = 240 # Height in pixels to resize thumbnails to
151151

152152

153-
VIDEO_HEIGHT_CUTOFF = 240 # Smallest resolution in pixels permitted to download
154-
VIDEO_HEIGHT_IS_HD = 500 # Height in pixels to count as 'HD'
153+
VIDEO_HEIGHT_CUTOFF = int(os.getenv("VIDEO_HEIGHT_CUTOFF", "240")) # Smallest resolution in pixels permitted to download
154+
VIDEO_HEIGHT_IS_HD = 500 # Height in pixels to count as 'HD'
155155

156156

157157
YOUTUBE_DL_CACHEDIR = None

0 commit comments

Comments
 (0)