fix: handle build_webpages returning None in WebsiteDeployer

Exception in _build_webpages was silently caught, returning None.
rsync then received "None/" as source path, silently breaking deploy.
This commit is contained in:
Alex V.
2026-02-07 16:29:14 +03:00
committed by missytake
parent 6b4edd8502
commit 31301abb42

View File

@@ -267,6 +267,9 @@ class WebsiteDeployer(Deployer):
# if www_folder is a hugo page, build it
if build_dir:
www_path = build_webpages(src_dir, build_dir, self.config)
if www_path is None:
logger.warning("Web page build failed, skipping website deployment")
return
# if it is not a hugo page, upload it as is
files.rsync(
f"{www_path}/", "/var/www/html", flags=["-avz", "--chown=www-data"]