Shipping software with built-in AI to air-gapped and classified networks
Every product roadmap has AI on it now, and federal buyers want it too. Then the questions come: "Does it work on our network?" "Do we need to hire an AI specialist?" On an air-gapped or classified network, there's no calling a vendor's model API. Either the model runs inside the boundary, or the feature doesn't exist. Or, more commonly, it does exist but the API is on a different network.
The good news is that this is mostly a design decision, and it's cheaper to make it early. Here's how I'd build it.
One code path, three modes
The single most useful decision: the application talks to a model only through an OpenAI-compatible HTTP endpoint, and the address comes from configuration. Almost every local model server speaks that API, and so do most model gateways that agencies run. The app never needs to know which one it's talking to.
That gives you three deployment modes with the same code:
+--> local model server (Ollama or vLLM) next to the app [bundled]
App --(OpenAI API)--+--> the agency's own model gateway [agency-hosted]
+--> nothing: AI features fall back to code-based rules [rules only]
The configuration is three or four values:
AI_MODE=local # local | agency | rules
AI_BASE_URL=http://127.0.0.1:11434/v1 # Ollama's default port; vLLM uses 8000
AI_MODEL=gpt-oss:20b
AI_CA_BUNDLE=/etc/pki/agency-ca.pem # agency gateways usually use an internal CA
That also answers "Do we need to hire an AI specialist?" No. With an OpenAI-compatible endpoint and a rules-only fallback, a system administrator can run the model server like any other service: install it, point the app at it, watch it, patch it.
Rules only is not an afterthought. Some sites will have no GPU, some won't approve any model, and some will approve one six months after your software. Design every AI feature so a deterministic version exists: the rules find the problem, and the model, when present, explains it in plain language. If the product cannot function without the model, it can't ship to the sites that need it most. This is where a lot of projects get abandoned in the prototype stage.
Agency-hosted is often the easiest path to approval. If the agency already runs an approved model, your software adds no new model to accredit. It's just another client of a service they've already authorized. Make the base URL, auth header and CA bundle configurable, and you're done.
Choosing a model: license and provenance first
For the bundled mode, quality matters less than you'd think. Accreditation cares about where the weights came from, what license they're under, and whether you can prove the file the site runs is the same file you tested.
- License. Prefer a plain open-source license. OpenAI's gpt-oss models (20b and 120b) are Apache 2.0. Some popular "open" models ship under custom licenses with acceptable-use clauses that a contracting officer will want to read first.
- Provenance. Avoid Chinese-origin weights for government buyers, and for the intelligence community above all. DeepSeek has already been banned on government devices at a number of agencies, and the proposed No Adversarial AI Act (introduced in Congress in June 2025) would bar federal use of AI from foreign adversaries. Even where it's allowed, explaining it in a security review costs more than choosing a different model.
- File format. Ship weights as safetensors or GGUF, never as pickle files, which can run code when they're loaded.
- Pin the hash. Record the SHA-256 of every weight file, check it at startup, and refuse to load a file that doesn't match.
Hardware: what each option needs
| Option | Hardware | Notes |
|---|---|---|
| Rules only | None beyond the app | Always available, the baseline every site gets |
| gpt-oss-20b | About 16 GB of memory | A single 24 GB GPU is comfortable. CPU-only works for light use, but answers are slow |
| gpt-oss-120b | A single 80 GB GPU (H100 or MI300X class) | Much better reasoning. Plan for one GPU server per site, not per user |
| Agency-hosted | Whatever the agency runs | Nothing extra on your side |
The weights also take disk: tens of gigabytes for larger models. In a disconnected site that matters for how you deliver updates, which comes up again below.
Size for your feature, not for a benchmark. Explaining a slow query, summarizing a log or drafting a report is well within the small model's range. Multi-step reasoning across many documents is where the larger one earns its GPU.
Serving the model: Ollama or vLLM
Both serve an OpenAI-compatible API, and both run fully offline once the weights are local.
- Ollama is a single binary and the simplest to install. Bind it to
127.0.0.1(the default) so only the app can reach it. SetOLLAMA_NO_CLOUD=1to turn off its cloud-model features, and pointOLLAMA_MODELSat a read-only volume holding the approved weights. - vLLM is built for throughput: many users, batching, multi-GPU. Note that vLLM collects anonymous usage statistics by default. Set
VLLM_NO_USAGE_STATS=1orDO_NOT_TRACK=1, and setHF_HUB_OFFLINE=1so it never tries to download from Hugging Face.
Whichever you choose, test it with the network cut off. A component that tries to phone home and fails silently in a lab will still show up in a firewall log at the site, and somebody will ask about it.
Guardrails that reviewers will ask about
- The model never acts on its own output unchecked. If it generates SQL, run it as a read-only role with a statement timeout and a row limit, on a replica if you have one. I covered why in The prototype became production.
- Keep the prompts and answers local, and log them. The logs contain whatever data went into the prompt, so they carry the same classification as the data.
- Make the AI optional per site, and visible. An administrator should be able to switch AI off with one setting, and users should be able to tell which text came from the model.
Getting through accreditation and the scans
None of this replaces the agency's ATO process, but it's what makes it go smoothly.
- No outbound calls, proven. List every network call the product can make: telemetry, update checks, license checks, web fonts, CDNs, crash reporting, model downloads. Remove them or put them behind a setting that's off by default. Then run the whole product with egress blocked and show that nothing breaks.
- An SBOM that includes the model. CycloneDX can describe machine learning models as components, so the weights can sit in the same SBOM as your libraries, with their source, license and hash.
- Pinned everything. Every dependency pinned to an exact version and hash, built from a hardened base image. Red Hat's UBI is the usual choice, and Iron Bank publishes UBI base images with STIG settings already applied.
- FIPS. Inference itself doesn't use cryptography, but TLS, hashing and signing do. Run on a FIPS-enabled host and image so Python and other runtimes use the system's validated OpenSSL. Go components can use Go's own FIPS 140-3 module (CMVP certificate #5247, Go 1.24 and later) by building with
GOFIPS140or settingGODEBUG=fips140=on. - Licensing that works offline. No license server. A signed license file that the site installs and renews by hand works everywhere.
- Updates as a package. Ship new versions, and especially new weights, as a signed, hashed bundle that the site can scan and carry across. Don't expect a site to pull anything.
For the platform pieces underneath (Postgres, Kafka, Trino and their STIGs and hardened images), see From a Postgres cluster to a hybrid lakehouse.
What Iron Bank is, and what it isn't
Iron Bank is the DoD's repository of hardened container images, and getting your image there makes it much easier for DoD programs to pull it in. A few things are worth knowing up front:
- It isn't a certification. Iron Bank's own FAQ says it does not authorize or approve containers. It builds them in its pipeline, scans them, and publishes an assessment: a compliance status and a risk score. Programs use that assessment in their own ATO.
- It isn't an ATO. You still need an authorization from the system you deploy into, unless that system already covers you (for example, a Platform One continuous ATO).
- Commercial software has to come from its owner. Iron Bank only accepts commercial products contributed by the company that owns them. You onboard through the Getting Started form on the Iron Bank documentation site.
- Every scan finding needs an answer. You fix it or justify it, on a deadline set by its severity. A justification only gets you through the first deadline. After that, findings need to be mitigated or fixed.
- Build inputs are declared and hashed. Anything the build downloads is listed in a hardening manifest with its URL and SHA-256. Large model weights may be better delivered as a separate, hashed artifact than baked into the image, so ask the onboarding team how they want it handled before you design around either option.
A checklist before you promise "it works on our network"
- The app reaches the model only through a configurable OpenAI-compatible endpoint.
- Every AI feature has a rules-only path that's still useful.
- Weights have a plain license, non-adversary origin, a safe file format and a pinned hash.
- The model server binds locally, with cloud features and usage stats turned off.
- The product runs with egress blocked, and you can prove it.
- The SBOM lists the model alongside the libraries.
- The image uses a hardened base, runs in FIPS mode, and has every scan finding answered.
- Licensing and updates work by carrying files across, not by connecting out.
Done this way, the same build serves a commercial customer with a GPU, an agency with its own model gateway and a classified enclave with no AI at all. If you've shipped AI features into a disconnected environment, I'd like to hear what tripped up your accreditation.
Brett Rosenblatt is a DBA and performance engineer and a co-founder of Bandlei, which makes ReinDB, a read-only performance monitor for PostgreSQL, Oracle and other databases.