X-Git-Url: http://p2p-next.cs.pub.ro/gitweb/?p=living-lab-site.git;a=blobdiff_plain;f=cis%2Fconfig.py;h=f19604ca3c422531436758757a2a90c1b6ae9c3f;hp=3e9ff6911dbbe1af3cf1105c4283de8824a2b29a;hb=080b37a97e93691b3ba1c4aa3982a143167115a7;hpb=3cf4f616f7d4095623ad5eae5db9fb1149ee1238 diff --git a/cis/config.py b/cis/config.py index 3e9ff69..f19604c 100644 --- a/cis/config.py +++ b/cis/config.py @@ -1,36 +1,57 @@ #!/usr/bin/env python +import logger + # Make here all necessary imports required for API classes. -from api import avhandling -from api import file_transfer +from api import ffmpeg +from api import ftp + + +# === GENERAL CONFIGURATIONS === +LOG_LEVEL = logger.LOG_LEVEL_DEBUG +SECURITY = False +START_DOWNLOADS_INTERVAL = 24 * 3600.0 # Once a day # === FILE TRANSFER CONFIGURATIONS === # Path from the Web Server where the raw input video file is stored. -INPUT_PATH = 'upload' +WS_UPLOAD_PATH = 'devel/data/upload' # Path from the Web Server where the output torrent files will be stored. -OUTPUT_TORRENTS_PATH = 'torrents' +WS_TORRENTS_PATH = 'devel/data/torrents' # Path from the Web Server where the output thumbnail image files will be # stored. -OUTPUT_THUMBS_PATH = 'thumbs' +WS_THUMBS_PATH = 'devel/data/thumbs' + + +# === URLS === +#BT_TRACKER = "http://p2p-next-10.grid.pub.ro:6969/announce" +# BitTorrent tracker URL. +BT_TRACKER = 'http://p2p-next-10.grid.pub.ro:6969/announce' +# Web server's URL for content ingestion completion. +WS_COMPLETION = 'http://p2p-next-03.grid.pub.ro:8081/cis_completion' +#WS_COMPLETION = 'http://koala.cs.pub.ro/video/cis_completion' -# === BITTORRENT CONFIGURATIONS === -BT_TRACKER = "http://p2p-next-10.grid.pub.ro:6969/announce" +# === CIS PATHS === +RAW_VIDEOS_PATH = 'tmp/raw' +THUMBS_PATH = 'tmp/thumbs' +MEDIA_PATH = '/home/p2p/export/p2p-tube/media' +# In a distributed file system for multi-CIS. +TORRENTS_PATH = '/home/p2p/export/p2p-tube/torrents' # === EXTERNAL PROGRAMS API CLASSES === # API class for a prgram which retrives audio/video information, like duration. -AVINFO_CLASS = avhandling.FFmpegAVInfo +AVINFO_CLASS = ffmpeg.FFprobeAVInfo # API class for a prgram which transcodes an audio/video file. -TRANSCODER_CLASS = avhandling.FFmpegTranscoder +TRANSCODER_CLASS = ffmpeg.FFmpegTranscoder # API class for a prgram which extracts thumbnail images from a file. -THUMB_EXTRACTOR_CLASS = avhandling.FFmpegThumbExtractor +THUMB_EXTRACTOR_CLASS = ffmpeg.FFmpegThumbExtractor # API class for a prgram which transfers files between Web Server and CIS. -FILE_TRANSFERER_CLASS = file_transfer.FTPFileTransferer +FILE_TRANSFERER_CLASS = ftp.FTPFileTransferer -# === EXTERNAL PROGRAMS BINARY FILES +# === EXTERNAL PROGRAMS BINARY FILES === # Set this values to None if you want default values provided by the API # class to be used. # Binary of a prgram which retrives audio/video information, like duration.