moved some files to archive

This commit is contained in:
Geir Okkenhaug Jerstad 2025-07-07 14:20:29 +02:00
parent ef4b4b7736
commit db9fadcb0a
25 changed files with 15 additions and 0 deletions

View file

@ -0,0 +1,18 @@
;; lab/core.scm - Core infrastructure operations (impure)
(define-module (lab core)
#:use-module (utils config)
#:use-module (utils ssh)
#:use-module (utils logging)
#:export (get-infrastructure-status))
;; Impure function: Get infrastructure status with side effects
(define (get-infrastructure-status)
"Get status of all machines (impure - has logging side effects)"
(log-info "Checking infrastructure status...")
(let ((machines (get-all-machines)))
(map (lambda (machine)
(let ((status (test-ssh-connection machine)))
`((machine . ,machine)
(status . ,(if status 'online 'offline)))))
machines)))