Deploy Flue Agents With Solo
Flue builds agent workspaces into ordinary HTTP servers. That makes it a useful fit for devopsellence: Flue owns the agent runtime, while devopsellence owns the VM deployment loop, secrets, health checks, logs, rollback, and TLS.
Flue is experimental and its APIs may change. This example was checked against
@flue/sdk and @flue/cli 0.3.10; verify the Flue commands locally before
using this shape in production.
Build The Flue App
Section titled “Build The Flue App”Create a minimal webhook agent:
mkdir my-flue-servercd my-flue-servernpm init -ynpm install @flue/sdk@0.3.10 @flue/cli@0.3.10 valibot@^1.0.0mkdir -p .flue/agentsimport type { FlueContext } from '@flue/sdk/client';import * as v from 'valibot';
export const triggers = { webhook: true };
export default async function ({ init, payload }: FlueContext) { const agent = await init({ model: 'openai/gpt-5.5' }); const session = await agent.session();
return await session.prompt(`Translate this to ${payload.language}: "${payload.text}"`, { result: v.object({ translation: v.string(), confidence: v.picklist(['low', 'medium', 'high']), }), });}Check the Node target before adding devopsellence:
npx flue build --target nodePORT=8080 node dist/server.mjsFrom another shell:
curl -fsS http://localhost:8080/healthcurl -fsS http://localhost:8080/agentsContainerize It
Section titled “Containerize It”FROM node:22-slim AS depsWORKDIR /appCOPY package.json package-lock.json ./RUN npm ci
FROM deps AS buildCOPY . .RUN npx flue build --target node
FROM node:22-slim AS runtimeWORKDIR /appENV NODE_ENV=productionENV PORT=8080
COPY package.json package-lock.json ./RUN npm ci --omit=devCOPY --from=build /app/dist ./dist
EXPOSE 8080CMD ["node", "dist/server.mjs"]cat > .dockerignore <<'EOF'.git.envnode_modulesdistEOFAdd Devopsellence Config
Section titled “Add Devopsellence Config”devopsellence init --mode soloschema_version: 1organization: soloproject: flue-agentdefault_environment: production
build: context: . dockerfile: Dockerfile platforms: - linux/amd64
services: web: ports: - name: http port: 8080 healthcheck: path: /health port: 8080 env: NODE_ENV: production PORT: "8080" secret_refs: - name: OPENAI_API_KEY secret: OPENAI_API_KEY
ingress: hosts: - flue.example.com rules: - match: host: flue.example.com path_prefix: / target: service: web port: http tls: mode: auto email: ops@example.com redirect_http: trueStore the provider key through devopsellence instead of committing .env:
printf '%s' "$OPENAI_API_KEY" | devopsellence secret set OPENAI_API_KEY --service web --stdinDeploy
Section titled “Deploy”Attach an existing VM:
devopsellence node create prod-1 --host <server-ip-or-hostname> --user root --ssh-key ~/.ssh/id_ed25519devopsellence agent install prod-1devopsellence node attach prod-1Then publish desired state:
devopsellence doctordevopsellence deploy --dry-rundevopsellence deploydevopsellence ingress check --wait 5mdevopsellence statusVerify Flue’s generated endpoints and one real agent route:
curl -fsS https://flue.example.com/healthcurl -fsS https://flue.example.com/agentscurl -fsS https://flue.example.com/agents/translate/prod-smoke \ -H "Content-Type: application/json" \ -d '{"text":"Hello world","language":"French"}'Node-target Flue sessions are in-memory by default. Add durable session storage inside the Flue app before relying on session history surviving restarts.