feat(backend): image endpoints toegevoegd

This commit is contained in:
kodi
2026-02-21 12:04:21 +01:00
parent acbf150e28
commit 1ed7699437
3 changed files with 162 additions and 1 deletions
+4 -1
View File
@@ -1,6 +1,7 @@
import os
import sys
import subprocess
from app_images import init_images_router
from fastapi import FastAPI, HTTPException, Query
from pydantic import BaseModel
import requests_unixsocket
@@ -16,7 +17,9 @@ PODMAN_API_BASE = "http+unix://%2Frun%2Fuser%2F1000%2Fpodman%2Fpodman.sock/v5.4.
BASE_DIR = os.path.dirname(os.path.abspath(__file__))
ALLOWLIST_FILE = os.getenv("ALLOWLIST_FILE", os.path.join(BASE_DIR, "allowed_units.txt"))
WORKLOADS_DIR = "/app/workloads"
# --- ROUTERS ---
# Images API lives in a dedicated module to keep this file from growing further.
app.include_router(init_images_router(SESSION, PODMAN_API_BASE))
# --- ADAPTERS (contract-neutral helpers) ---
# Centralize Podman socket and systemctl invocation.