aur-shield v0.1.0: AI-powered AUR firewall
- FastAPI server with scan/build/repo endpoints - LLM scanner (Ollama) with regex pre-scan - makepkg/devtools builder with chroot isolation - Scan cache with TTL + PKGBUILD hash - Client installer + safe-yay wrapper - Docs + config example
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
"""Main entry point for AUR-Shield."""
|
||||
from __future__ import annotations
|
||||
|
||||
import sys
|
||||
|
||||
import uvicorn
|
||||
|
||||
from .config import Config
|
||||
from .server import init_server
|
||||
|
||||
|
||||
def main() -> None:
|
||||
config_path = sys.argv[1] if len(sys.argv) > 1 else "config.yaml"
|
||||
config = Config.load(config_path)
|
||||
|
||||
init_server(config)
|
||||
|
||||
print(f"AUR-Shield v0.1.0")
|
||||
print(f" Model: {config.ollama.model}")
|
||||
print(f" Ollama: {config.ollama.url}")
|
||||
print(f" Repo: {config.server.repo_dir}")
|
||||
print(f" Listening on {config.server.host}:{config.server.port}")
|
||||
|
||||
uvicorn.run(
|
||||
"aur_shield.server:app",
|
||||
host=config.server.host,
|
||||
port=config.server.port,
|
||||
reload=False,
|
||||
)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
||||
Reference in New Issue
Block a user