Host non-YouTube videos on a separate server
This commit is contained in:
parent
446ed2256a
commit
99061ce7ec
|
@ -44,8 +44,6 @@ def setup_directory_structure(settings, base_dir, template_dir):
|
|||
site_new_dir = os.path.join(base_dir, 'site-new')
|
||||
shutil.rmtree(site_new_dir, ignore_errors=True)
|
||||
os.mkdir(site_new_dir)
|
||||
extern_dir_site = os.path.join(site_new_dir, 'extern')
|
||||
os.symlink(os.path.join('..', 'extern'), extern_dir_site)
|
||||
|
||||
style = read(os.path.join(template_dir, 'style.css'))
|
||||
style_out = style.replace('{', '{{').replace('}', '}}') \
|
||||
|
@ -83,7 +81,7 @@ def generate_video_section_html(section_html, media):
|
|||
return html_out
|
||||
|
||||
def extern_video(file_src):
|
||||
url = '../extern/' + file_src
|
||||
url = 'https://f000.backblazeb2.com/file/media-metanohi-name/media/' + file_src
|
||||
return '''\
|
||||
<video src="{url}" controls height="427">
|
||||
Your browser cannot play this video. You can download it here instead:
|
||||
|
|
Loading…
Reference in New Issue