X-Git-Url: https://wannabe.guru.org/gitweb/?a=blobdiff_plain;f=local_photos_mirror_renderer.py;h=b6499a17bd39a13ad0e011db94cb963bfb6269d9;hb=55bcd1ba1b9d481e0d0dc604932bcc0f7f4fa127;hp=390d6eabef0eab0d6230ad3075e10d012c4623a7;hpb=e4dca16bbd329afdb587e8488767d88e17777254;p=kiosk.git diff --git a/local_photos_mirror_renderer.py b/local_photos_mirror_renderer.py index 390d6ea..b6499a1 100644 --- a/local_photos_mirror_renderer.py +++ b/local_photos_mirror_renderer.py @@ -3,16 +3,16 @@ import os import random import re -from typing import List, Dict, Set +from typing import Dict, Set import file_writer import renderer -class local_photos_mirror_renderer(renderer.debuggable_abstaining_renderer): +class local_photos_mirror_renderer(renderer.abstaining_renderer): """A renderer that uses a local mirror of Google photos""" - album_root_directory = "/usr/local/export/www/gphotos/albums" + album_root_directory = "/var/www/html/kiosk/images/gphotos/albums" album_whitelist = frozenset( [ @@ -36,9 +36,11 @@ class local_photos_mirror_renderer(renderer.debuggable_abstaining_renderer): "Newer Alex Photos", "Ohme Gardens", "Olympic Sculpture Park", + "Portland, ME 2021", "Prague and Munich 2019", "Random", "Scott and Lynn", + "Sculpture Place", "SFO 2014", "Skiing with Alex", "Sonoma", @@ -47,6 +49,7 @@ class local_photos_mirror_renderer(renderer.debuggable_abstaining_renderer): "Trip to East Coast '16", "Tuscany 2008", "Yosemite 2010", + "WA Roadtrip, 2021", "Zoo", ] ) @@ -62,7 +65,7 @@ class local_photos_mirror_renderer(renderer.debuggable_abstaining_renderer): ) def __init__(self, name_to_timeout_dict: Dict[str, int]) -> None: - super(local_photos_mirror_renderer, self).__init__(name_to_timeout_dict, False) + super().__init__(name_to_timeout_dict) self.candidate_photos: Set[str] = set() def debug_prefix(self) -> str: @@ -94,7 +97,7 @@ class local_photos_mirror_renderer(renderer.debuggable_abstaining_renderer): if extension in self.extension_whitelist: photo_path = os.path.join(root, filename) photo_url = photo_path.replace( - "/usr/local/export/www/", "http://10.0.0.18/", 1 + "/var/www/html", "http://kiosk.house/", 1 ) self.candidate_photos.add(photo_url) return True