Commit b7b936c5 authored by Dave Cooper's avatar Dave Cooper
Browse files

add signal to pid 1 script, not childly spawned process

parent de5e61b5
Loading
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -4,7 +4,7 @@ ARG DEBIAN_FRONTEND=noninteractive

RUN apt-get -y update && apt-get -y upgrade && apt-get -y autoremove && \
    apt-get -y install openssl libssl-dev iputils-ping telnet ghostscript wamerican \
    zlib1g-dev libc6-dev curl gcc libc-dev make && \
    zlib1g-dev libc6-dev curl  && \
    rm -rf /var/cache/apt/* && apt-get clean

# Install Docker CLI using static binary (matching lisply-mcp and skewed-emacs approach)
+8 −0
Original line number Diff line number Diff line
#!/bin/bash

cleanup() {
    echo "Shutting down Gendl daemon..."
    exit 0
}

trap cleanup SIGTERM


HTTP_PORT=${HTTP_PORT:-9080}  # Single source of truth for HTTP port

if [ -f /opt/gendl/gdl/program/gdl-ccl ]; then
+0 −10
Original line number Diff line number Diff line
(in-package :common-lisp-user)


(defun exit-on-signal (signo)
  (format t "~&received ~A~%"
	  (trivial-signal:signal-name signo))
  (case signo
    ((15 9) (uiop:quit 0))
    (t (format t "Doing nothing.~%"))))

(setf (trivial-signal:signal-handler :term) #'exit-on-signal)

;; now run `kill -15 $PID` on the terminal to run `exit-on-signal`


+1 −1
Original line number Diff line number Diff line
"(:glisp #-allegro :cl-html-parse #+(or ccl sbcl allegro) :zaserve  #-(or ccl sbcl allegro) :aserve :cl-who :yason :cl-markdown :cl-json :trivial-signal)"
"(:glisp #-allegro :cl-html-parse #+(or ccl sbcl allegro) :zaserve  #-(or ccl sbcl allegro) :aserve :cl-who :yason :cl-markdown :cl-json)"
+1 −1
Original line number Diff line number Diff line
@@ -5,7 +5,7 @@
 "Dave Cooper, Genworks International" :license
 "Affero Gnu Public License (http://www.gnu.org/licenses/)" :serial t
 :version "20250417" :depends-on
 (:glisp #-allegro :cl-html-parse #+(or ccl sbcl allegro) :zaserve  #-(or ccl sbcl allegro) :aserve :cl-who :yason :cl-markdown :cl-json :trivial-signal)
 (:glisp #-allegro :cl-html-parse #+(or ccl sbcl allegro) :zaserve  #-(or ccl sbcl allegro) :aserve :cl-who :yason :cl-markdown :cl-json)
 :components
 ((:file "source/package") (:file "source/defparameters")
  (:file "source/base-html-sheet") (:file "source/html-format")