1. core
2. demo
3. infra
3.1. man
Archived entries from file /home/ellis/src/org/docs/infra/man.org
3.1.1. bootstrap.sh
(ql:quickload '(:dat :cli))
(in-package :dat/dot)
(let ((g (make-instance 'simple-directed-graph)))
(add-node g :check)
(add-node g :bootstrap)
(add-node g :autogen)
(add-node g "profile.sxp")
(add-node g "host.sxp")
(add-edge g '(:check "host.sxp"))
(add-edge g '(:bootstrap :check))
(add-edge g '(:bootstrap :autogen))
(add-edge g '("profile.sxp" :autogen))
(add-edge g '("host.sxp" :autogen))
(serialize g :dot :path #p"/tmp/bootstrap.dot")
(sb-ext:run-program (cli:find-exe "dot") (list "-Tsvg" "/tmp/bootstrap.dot" "-o" "/tmp/bootstrap.svg")))
The easiest way to get started is to run the top-level script
bootstrap.sh. Running the script will:
- run
check.sh - install the latest cores and lisp runtime from https://packy.compiler.company to the stash
- load
autogen.lispand call the functioninfra/autogen:autogen- check and apply the host config and profile
- build all features in parallel
Upon completion a local stash directory is provisioned. At this
point we no longer need to depend on shell scripting as we have a
fully interactive Lisp environment to hack on our builds with.
From here, you may run skel inspect to inspect the infra skelfile
and select a target to build on your machine or in a container. Use
skel --help for a list of other commands.
- check.sh
This script checks that the current host is qualified. It needs to be ran once before the
autogen.lispfile is loaded, usually viabootstrap.sh.This will interrogate the system, checking for minimum requirements. If any requirement isn't met an error is signaled. On completion, the name of an SXP file is printed which contains the host config.
The minimum software dependencies above should be installed via your system's package manager.
./check.sh - autogen.lisp
Once a core and lisp runtime are available, we load
autogen.lispand callinfra/autogen:autogen. This will process the host configuration (zor.sxpin the example above) and the profile (defaults todefault.sxp), update environment variables for the current shell and take any additional actions needed.The order of operations are loosely as follows:
- initialize profile
- update host environment variables
- check features and ensure host dependencies
- initialize host
- initialize infra
skelfile - process all features
- quit
3.1.2. TODO deploy.lisp
Deploy infra builds to a remote.
Deployment involves 'packing' a target found in stash, archiving it,
compressing it, and sending it to a remote location possibly with a
signature, checksum, other metadata, or encrypted. A 'package' may
also be a raw directory of plain-text files. It's a very loose
term. Where the package ends up and how it is packed depends on the
build-config and skelfile slots.
Production deployments end up at https://packy.compiler.company.
3.1.3. TODO install.lisp
Install core packages locally.