|
@@ -16,7 +16,7 @@ import yaml |
|
|
from pathlib import Path |
|
|
from pathlib import Path |
|
|
import logging |
|
|
import logging |
|
|
|
|
|
|
|
|
logging.basicConfig(filename='demotape.log', level=logging.INFO) |
|
|
|
|
|
|
|
|
logging.basicConfig(filename='/var/log/demotape.log', level=logging.INFO) |
|
|
logging.info("Starting demotape service at " + str(datetime.utcnow())) |
|
|
logging.info("Starting demotape service at " + str(datetime.utcnow())) |
|
|
|
|
|
|
|
|
config_path = Path(__file__).parent / './config.yaml' |
|
|
config_path = Path(__file__).parent / './config.yaml' |
|
@@ -96,7 +96,7 @@ def my_ytdl_hook(d): |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
def download_stream(channel, dest_path): |
|
|
def download_stream(channel, dest_path): |
|
|
logging.info('download_stream') |
|
|
|
|
|
|
|
|
logging.info(timestamp() + ' download_stream') |
|
|
ytdl_opts = { |
|
|
ytdl_opts = { |
|
|
'logger': MyLogger(), |
|
|
'logger': MyLogger(), |
|
|
'outtmpl': dest_path, |
|
|
'outtmpl': dest_path, |
|
|