From 48adf9d151b808918b4b62ad4455a0a0edb7b4f4 Mon Sep 17 00:00:00 2001 From: kolaente Date: Fri, 3 Nov 2017 20:24:24 +0100 Subject: [PATCH] updated readme --- README.md | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index 5b531d7..999e699 100644 --- a/README.md +++ b/README.md @@ -2,29 +2,33 @@ This image provides an easy way to convert a video file in multiple different output formats. Just specify a folder which holds the video files, it will automatically watch it and convert everything you specify. +It will create a new folder for each video which will hold all outputted formats. Once finished, it creates a file `[videoname].done` in said folder to indicate it is done. It will also move (and rename) the original file to this folder. + # Running, the easy way +The following command will convert all `mp4` and `webm` videos to `webm` files. + ```bash docker run -v /var/run/docker.sock:/var/run/docker.sock -v /path/to/video/files:/var/videos --name videodecoding --env VIDEO_FOLDER=/path/to/video/files --env VIDEO_FORMATS='.mp4':'.webm' kolaente/video-decode ``` # Options --c: Video Formats Location. Pass a path with a JSON config file for conversion. Defaults to 'video_formats.json' in current folder. --p: Video Location. Pass a location to a different folder which holds the videos. Defaults to currents folder. --v: Video Formats. Pass all video formats which should trigger the conversion, seperated by ':'. Example: .mp4:.wmv - -ENVIRONMENT VARIABLES: All settings can be done via environment variables passed to the container. -VIDEO_FORMATS_LOCATION: Pass a location to a different json file holding video convert configurations -VIDEO_LOCATION: Pass a location to a different folder which holds the videos -VIDEO_FORMATS: Pass all video formats which should trigger the conversion, seperated by ':. Example: .mp4:.wmv +* __VIDEO_FORMATS_LOCATION__: Pass a location to a different JSON file holding video convert configurations (see below for more informations about that file). +* __VIDEO_FORMATS__: Pass all video formats which should trigger the conversion, seperated by ':. Example: .mp4:.wmv + +## Video location + +Videos are placed in `/var/videos` inside the container. Mount a folder from your host holding the videos. # Specify output video formats This is done via a JSON file at `/var/videoconversion/config/video_formats.json`. You can mount `/var/videoconversion/config/` to your host and specify your own formats. +`framerate` is the only one optional. You _need_ to specify everything else. + Standard configuration looks like this: ```json