Files
Donavan Fritz 8cc34552c6 strip docker type — site-publish is static-content only
Removes type: docker handling from action.yaml, scripts (build/deploy/utils/setup),
and templates (deployment.yaml.j2, service-docker.yaml.j2). Renamed
service-static.yaml.j2 -> service.yaml.j2.

If site.yaml has type: docker, parse_site_yaml() now dies with a clear message
pointing to action/image-build + action/image-push + action/image-deploy with
hand-authored apps-repo manifests. rainsounds.vino.network was the only docker
consumer and has already migrated.

Drops registry-password input from action.yaml (no longer needed).
2026-05-06 10:01:09 -05:00

42 lines
1.1 KiB
Python

"""Ensure required CLI tools are installed."""
import os
import shutil
import subprocess
import sys
def ensure_aws():
if shutil.which("aws"):
subprocess.run(["aws", "--version"], check=True)
return
print("Installing awscli...")
subprocess.run(
[sys.executable, "-m", "pip", "install", "--quiet", "--break-system-packages", "awscli"],
check=False,
)
local_bin = os.path.expanduser("~/.local/bin")
os.environ["PATH"] = f"{local_bin}:{os.environ['PATH']}"
github_path = os.environ.get("GITHUB_PATH")
if github_path:
with open(github_path, "a") as f:
f.write(f"{local_bin}\n")
subprocess.run(["aws", "--version"], check=True)
def ensure_jinja2():
try:
import jinja2
except ImportError:
print("Installing jinja2 + pyyaml...")
subprocess.run(
[sys.executable, "-m", "pip", "install", "--quiet", "--break-system-packages", "jinja2", "pyyaml"],
check=True,
)
if __name__ == "__main__":
ensure_jinja2()
ensure_aws()
print("Setup complete")